changeset 142:6f24ad61a32c

created
author 127.0.0.1
date Wed, 29 Jan 2014 20:09:30 +0100
parents fd3167f59b56
children 19cfc45f1db9
files input
diffstat 1 files changed, 13 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/input	Wed Jan 29 20:09:30 2014 +0100
@@ -0,0 +1,13 @@
+**Wrong:**
+{{{#!python
+x = input("Enter x:")
+y = input("Enter y:")
+print "x + y = %d" % (x + y)
+}}}
+
+**Better:**
+{{{#!python
+x = int(raw_input("Enter x:"))
+y = int(raw_input("Enter y:"))
+print "x + y = %s" % (x + y)
+}}}
\ No newline at end of file