Scripting >> Python >> Examples >> Strings >> How to loop through the characters in a string

StringVar = "banana"

for letter in StringVar :
    print letter

 

alternatively

for letter in "banana" :
   print letter