Ask your own question, for FREE!
MIT 6.00 Intro Computer Science (OCW) 22 Online
OpenStudy (anonymous):

my english is bad so i don't know if you understand me. i learn python language, I need to make program that user must type names of 3 cities,and if user type same city again program must tell him something like " that city already exist,type again!" and in the end program must tell him how many times did he write the same city or cities..I don't know if this is understandable but I need help..thanks :)

OpenStudy (e.mccormick):

How far did you get with the code?

OpenStudy (anonymous):

i know write till the end, the problem is in last excercise where program needs to show how much times user is write the same city.

OpenStudy (e.mccormick):

You should have a variable that tracks that. Every time it happens, add one to it.

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!