Question

Consider the following Python code: text = "banana" char_to_find = 'a' count = 0 for i in range(len(text)):     if text[i] == char_to_find:         count += 1         if count == 2:             print(i)             break What will be the output of this code?

A 1
B 3
C 5
D 2
E None (no output)
Practice Next

Hey! Ask a query