Creation and use of strings

--Originally published at angelmendozas

Strings are extremely useful in python programming, they can arrange data, return frases with data the user inputs, and several more things but in its most basic way you crate variables and ask the program to return whatever you want it to return.

potato1:’I love Canada’

potato2:’I hate Trump’

those are our variables, potato 1 and 2.

then we can ask the program to return part of the sentence as we know counting from zero (zero=one, the first word in the sentence)

print potato1[0:]

print potato2[6:]

Potato 1 will return ‘I love Canada’ and potato 2 will return ‘Trump’