Skip to content

Commit cc99f74

Browse files
Merge pull request geekcomputers#172 from ayush1999/patch-1
NameError fix calculator.py
2 parents 5145ae0 + c3fbc5e commit cc99f74

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

calculator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def calc(k):
4444

4545
print ("\nScientific Calculator\nEg: pi * sin(90) - sqrt(81)")
4646

47-
k = input("\nWhat is ")
47+
k = raw_input("\nWhat is ") # Using input() function is causing NameError. Changing it to raw_input() fixes this.
4848

4949
k = k.replace(' ', '')
5050
k = k.replace('^', '**')

0 commit comments

Comments
 (0)