Python programming language provides many ways how to use strings in print function. For Python beginners, or even experts is worth to know that there are few types of Strings in Python. We can use strings variables with %s mark, either as use format definition, o we can use f strings in our Python projects.
f strings are the most flexible and fastest type among all strings in Python. This experiment based on CPU computation, with wall time test (%%time magic function in Jupyter Notebook).
In this video I demonstrate how f strings differ from classical ones and what you can do with this kind of strings in Python, and how f strings are more usable than others.
The content of the video:
0:00 - Intro (Content)
0:07 - Standard String with %s (not f String)
1:04 - Standard String with Format (not f String)
1:58 - f Strings (Simple Example)
2:49 - f Strings (printing list of tuples in a loop)
4:10 - f Strings (Reserve spaces for variables in text)
5:10 - f Strings (Align variables text by RIGHT side)
5:54 - f Strings (Align multiple variables by LEFT and RIGHT side)
7:16 - Learn More with other print functions in Python
7:50 - Outro.
The link to the bonus video (Learn More part): • 4 Python Functions That Makes Your Life Ea... (4 Python Functions That Makes Your Life Easier).
(Sorry, there no audio in this video)
Thank you for watching this video. I hope it was useful. Never Stop Learning!
#pythonprogramming
#fstrings
#pythontips
На этой странице сайта вы можете посмотреть видео онлайн f Strings in Python 3.X with Examples | Python Programming for Beginners длительностью часов минут секунд в хорошем качестве, которое загрузил пользователь Data Science Garage 26 Декабрь 2020, поделитесь ссылкой с друзьями и знакомыми, на youtube это видео уже посмотрели 884 раз и оно понравилось 18 зрителям. Приятного просмотра!