TypeError: can't multiply sequence by non-int of type 'str'

I think you are trying to multiply two numbers icontact and infection_rate, but they are strings.

You can do B_one=float(icontact)*float(infection_rate).

Or you can set type property of the InputBox to number.

5 Likes