print() function and Strings in Python
In this post, you will learn how to work with the print()
function and with strings so that you can use that same knowledge and thus evolve.
- the
print()
function prints its entire contents to the command line; - a string is a set of characters (letters, numbers and/or symbols);
- all strings are initialized and ended with apostrophes (‘string’) or with quotation marks (“string”);
- the escaped character is
\
and aims to make the character that follows part of the string.
print('We are using the print() function and I am a string.')
print("I'm still a string.")
print('Maria said that Miguel was "sick".') # Maria said that Miguel was "sick".
print('I\'m writing in English.') # I'm writing in English.
print('Caffeine', 'Algorithm') # Caffeine Algorithm
Don’t forget to watch the video and you can always read this post in Portuguese.