Install Python on Mac : First code using PyCharm

Install Python On Mac

Python is the most popular programming language, used for Artificial Intelligence, Machine Learning, backend development, and more. In this comprehensive tutorial, I will show you how to install Python on your Mac and write your first “Hello, World!” program using Python and PyCharm.

Step 1 : Download Python

Step 2: Install the downloaded file

  • Now just double click on downloaded .pkg file which will open the Installer. 
  • Just click on pressing continue this will install python on our system.
Install Python on Mac
Install Python on Mac

So, python has been successfully installed in our system. Now, to run first python program we will download pycharm. 

Step 3: Download PyCharm

  • Now to download PyCharm Community Edition. Just click on the following link
  • Download Link Pycharm : https://www.jetbrains.com/pycharm/download/?section=mac
  • Just download the dmg file and double click on it. 
  • And simply drag and drop into applications to install on the system.
Install Pycharm
Install Pycharm

Step 4: Create project using PyCharm

  • Now just create new project using pycharm. 
  • Click on “New Project”
  • Just Give Project Name “HelloWorld” and choose the just install version of python. 
  • And click on “create”
Create New Project
Create New Python Project
  • Now right click on HelloWorld project and create new python file. 
Create New Python file
Create New Python file
  • Now create a new Python file with name “HelloWorld.py”
Create Python file "HelloWorld.py"
Create Python file "HelloWorld.py"

Step 5: Write Python Code

  • Now Let’s write Program to display “Hello, World!”
Output of python program
  • Now simply right click and run prorgam. 

Step 6: Run Python Code

  • Now simply right click and click on run ‘HelloWorld’. 
Run Python file
Run Python file
  • The output will look like this.
Output
Output

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top