# python typeerror: can't multiply sequence by non-int of type 'float'

235 views

## Problem :

I'm new to python and I've been struggling with this problem for a while. I've search google and youtube but no luck so far. I've written this in IDLE 2.6.5. If someone could tell me why I'm getting the can't multiply sequence by non-int of type float error.

## Solution:

The can't multiply sequence by non-int of type 'float' error was because the input taken in the text-box is a string.

#c = self.input.GetValue()#

the value is still a string. Therefore, that value in c has to be converted, in this case to a float type:

#c = float(c)#

so Python can process it as part of the equation:
#c = 9.0/5.0 * c + 32#

https://github.com/OpenDroneMap/PyODM/issues/5

## Related questions

3 views
Problem: Give me an answer please >Can't multiply sequence by non-int of type 'float' python
1 vote
5 views
Problem: Any ideas on what I need to do to fix this? python can't multiply sequence by non-int of type 'float'
28 views
Problem: I am typing to get a sale amount (by input) to be multiplied by a defined sales tax (0.08) and then have it print the total amount (sales tax times sale amount). I run into this error. Anyone know what could be wrong or have any suggestions?
425 views
Problem : While submitting the Python program i am getting below error python can't multiply sequence by non-int of type 'float'
6 views
typeerror: can't multiply sequence by non-int of type 'float'
12 views
Problem: I'm only new, so don't be too harsh if this is really obvious, but why am i getting this error? >>> Enter muzzle velocity (m/2): 60 Enter angle (degrees): 45 Traceback (most recent call last): File "F:/Python31/Lib/idlelib/test", line 9, in <module> range() File " ... (2*(x*x))((decimal(math.zsin(y)))*(decimal(math.acos(y)))))/2) TypeError: can't multiply sequence by non-int of type 'str'
52 views
Problem: Hi! I am new to the world of programming. I am trying to multiply two numbers that will be entered by the user. I wrote the following program: number1 = input("Enter first number: ") number2 = input("Enter second number: ") print(number1," * ",number2," = ", ... = ",number1*number2) TypeError: can't multiply sequence by non-int of type 'str' I have no idea what I am doing wrong. Any help?