← Projects

String reverse done

6bce6ca2ae91b2eebad1d32ed970969ea5e423a2 · Karan Goel · Jul 11, 2013 07:23

+8 · 1 file changed

  • Text/reverse.py +8 −0
diff --git a/Text/reverse.py b/Text/reverse.py
new file mode 100644
index 0000000..eb97aec
--- /dev/null
+++ b/Text/reverse.py
@@ -0,0 +1,8 @@
+# -*- coding: cp1252 -*-
+"""
+Reverse a String  Enter a string and the program
+will reverse it and print it out.
+"""
+
+string = raw_input("Whatchu wanna say to me? ")
+print "You say %s, I say %s" % (string, string[::-1])