Ministério da Educação
Brasil um país de todos
Personal tools
Navigation
Log in


Forgot your password?
 
Document Actions

slides06ex2.py

by Cicero Garrozi last modified 2015-04-28 07:14

Click here to get the file

Size 1 kB - File type text/python-source

File contents

s = raw_input("Digite o seu nome: ")
#print s[::-1].upper()

#maneira mais trabalhosa:
nova = ""
#for i in s:
#    nova = i.upper() + nova
#print nova

#outra maneira:
for i in range(len(s)-1, -1, -1):
    nova += s[i].upper()
print nova

Powered by Plone CMS, the Open Source Content Management System

This site conforms to the following standards: