Advertisement
sissou123

Untitled

Mar 27th, 2022
607
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.67 KB | None | 0 0
  1. Python Print Variable – How to Print a String and Variable
  2. In this tutorial, you'll see some of the ways you can print a string and a variable together.
  3.  
  4. Let's get started!
  5.  
  6. How to use the print() function in Python
  7. To print anything in Python, you use the print() function – that is the print keyword followed by a set of opening and closing parentheses,().
  8.  
  9. #how to print a string
  10. print("Hello world")
  11.  
  12. #how to print an integer
  13. print(7)
  14.  
  15. #how to print a variable
  16. #to just print the variable on its own include only the name of it
  17.  
  18. fave_language = "Python"
  19. print(fave_language)
  20.  
  21. #output
  22.  
  23. #Hello world
  24. #7
  25. #Python
  26. for more:https://www.clictune.com/eAiY
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement