# Likepythons.py Copyright (c) 2006 Kari Laitinen # http://www.naturalprogramming.com # 2006-05-27 File created. # 2006-05-30 Last modification. # Programs Likejavas.java, likecpps.cpp, and Likecs.cs # demonstrate how switch-case constructs can be used in # the Java/C++/C# programming languages. # Python does not have the switch-case constructs. # Therefore, this program is the same as Likepython.py print "\n Do you like the Python programming language?" \ "\n Please, answer Y or N : ", character_from_keyboard = raw_input() if character_from_keyboard == 'Y' or \ character_from_keyboard == 'y' : print "\n That's nice to hear." elif character_from_keyboard == 'N' or \ character_from_keyboard == 'n' : print "\n That is not so nice to hear. " \ "\n I hope you change your mind soon." else : print "\n I do not understand \"%s\"." % character_from_keyboard