0
help
I tried to apply what I learned today and I don't think my result is correct. I need help please. https://sololearn.com/compiler-playground/c28fK4xyyOWr/?ref=app
2 Answers
+ 2
input() always returns a string. So if we enter
"1"
"2"
and want to perform mathematical operations, we first need to convert the values to a numeric data type. You can use float() or int() to convert to a number.
+ 1
nember_1 = int(input())
#Here you will get an integer
nember_2 = float(input())
#Here you will get a floating-point number