Oct-26-2023, 01:57 PM
Best regards, I kindly ask you, I have a problem and I have just started using Python, I have spent hours trying to solve this little question but I can't get it unstuck
I have tried in many ways but I get errors regarding float and string and unicode which does not can be put together.
thank you
import requests from bs4 import BeautifulSoup url = "https://www.sito web" r = requests.get(url) soup=BeautifulSoup(r.text, 'html.parser') print(soup.title.text)in this way, in a very curious way, he takes exactly the data I need from a web page even though I haven't explained to him in detail where it is, but I would like that once the data has been retrieved, which is something like 0.00000120, he would make a comparison with a value fixed set by me for example 0.00000110 and if the value retrieved from the web page is greater than 0.00000110 then write to me the value otherwise write to me "the value is lower!
I have tried in many ways but I get errors regarding float and string and unicode which does not can be put together.
thank you