Well I need to do this multiplication but give the following error:
Traceback (most recent call last):
File "C:\Users\Guilherme\Desktop\dasdsa.py", line 17, in <module>
conta = (trans1) * trans2
TypeError: can't multiply sequence by non-int of type 'tuple'
What do I do? Do I need a type of variable that does the comma multiplication? because I tried to float but it still did not work, I could not convert trans1 to float, what are my options?
MY CODE:
import urllib.request
page = urllib.request.urlopen("http://dolarhoje.com/")
text = page.read().decode("utf8")
price = text[9938:9942]
trans1 = (price)
tuple(price)
usertap = input("Coloque o real aqui:")
trans2 = tuple(usertap)
conta = (trans1) * trans2
print(conta)