Make this function
Wow! You are excited to see how fast and easy f-strings worked. So you plan to rewrite some more of your old code.
Now you know that f-strings allow you to evaluate expressions where they appear and include function and method calls. You decide to use them in a project where you analyze 120 tweets to check if they include links to different news. In that way, you expect the code to be cleaner and more readable.
The variables number1
, number2
,string1
, and list_links
have already been pre-loaded.
If you want to explore the variables, you can use print()
to view them in the IPython Shell.
Diese Übung ist Teil des Kurses
Regular Expressions in Python
Interaktive Übung
Versuche dich an dieser Übung, indem du diesen Beispielcode vervollständigst.
# Include both variables and the result of dividing them
print(f"___ tweets were downloaded in ____ minutes indicating a speed of ____ tweets per min")