how to find the index of the value where a number is located in python code example Example: python find index by value >>> ["foo", "bar", "baz"].index("bar") 1