Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Intermediate Git 2020
Demo 2
Commits
02baeedf
Commit
02baeedf
authored
Nov 01, 2020
by
Gilles Coremans
Browse files
Fix input parsing bug
parent
360845e8
Changes
1
Hide whitespace changes
Inline
Side-by-side
calc.py
View file @
02baeedf
...
@@ -9,9 +9,9 @@ except ValueError:
...
@@ -9,9 +9,9 @@ except ValueError:
exit
(
1
)
exit
(
1
)
try
:
try
:
operand2
=
int
(
operand
1
)
operand2
=
int
(
operand
2
)
except
ValueError
:
except
ValueError
:
print
(
operand
1
+
" is not a number!"
)
print
(
operand
2
+
" is not a number!"
)
exit
(
1
)
exit
(
1
)
print
(
"Your result is:"
)
print
(
"Your result is:"
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment