Python PPT Lesson 2
Python PPT Lesson 2
• Now that we are acquainted with Python and its features as a programming
language, let’s begin using it. In this lesson, we will install Python and the
PyCharm IDE on a computer running on a Windows operating system.
Objectives
After studying this lesson, you should be able to:
• download the Python and PyCharm installers;
• install Python and PyCharm; and
• go over PyCharm’s features and GUI.
Installing and Downloading
Python
You can save your Python (.py) files and run them within IDLE.
Hello, World!
Enter this line of code:
Click the Run button.
Notice how PyCharm automatically shifts focus to the Run tool window.
print()
▪ The print() function prints the specified message or text to the screen, or other
standard output device.
▪ The message or text can be a string, or any other object, the object will be
converted into a string before written to the screen.
Syntax:
print(object(s), sep=separator, end=end, file=file, flush=flush)
print()
Syntax:
print(object(s), sep=separator, end=end, file=file, flush=flush)
Example:
• Print a message onto the screen:
Example:
• Print more than one object:
Example:
• Print two messages, and specify the separator: