human
get index of character in python list
assistant
Here is some code to get index of character 'b' in list '['a', 'b']'

['a', 'b'].index('b')

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.