We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d12bde7 commit 9920293Copy full SHA for 9920293
Status/Day 9.md
@@ -98,6 +98,27 @@ printValue("3","4") #7
98
sum = lambda s1,s2 : int(s1) + int(s2)
99
print(sum("10","45")) # 55
100
```
101
+**Solution by VK: Python 3**
102
+
103
+```python
104
+def ConvertStrAndSum():
105
+ counter = 0
106
+ while counter == 0:
107
+ try:
108
+ value = input('Enter 2 value to sum it\n').split()
109
+ x, y = value
110
111
+ x, y = int(x), int(y)
112
+ counter += 1
113
+ return x + y
114
+ except ValueError as err:
115
+ print(err)
116
+ except ValueError or UnboundLocalError as err:
117
118
119
+print(ConvertStrAndSum())
120
+```
121
122
123
---
124
0 commit comments