Ana Sayfa » How To Learn Python Step By Step

How To Learn Python Step By Step

Yazar: Mesut Demirbas
Python Training - Introduction to Python

What is Python, how to download and how to install, what is Pycharm and how to install, Python Hello World how to write and python comment lines want to learn how to use it?

What is Python?

Python is an open source, easy-to-learn, free and high-level programming language developed by Guido Van Rossum in the early 1990s.

Why Python?

Python is an easy language to learn. Syntax is simple and simple. Like other languages, the program can be developed quickly without the need for assembly. It’s independent of platforms. This means that you can run the program that you type on all operating systems with minor changes.

What Can Be Done With Python?

Web and interface development, network socket programming, spider-type software, artificial intelligence, machine learning, hacking tools, game development, numerical and scientific calculations, data mining, analysis applications, and desktop applications can be implemented by developing software in many other areas.

With Python, large organizations such as Google, NASA, Wikipedia, Yahoo, CERN and Dropbox have made improvements. For example, Google web browsing spiders are written in Python. Python is also the most preferred software language in many areas, including combating cybercrime, infiltration testing, reverse engineering and hacking tools.

We have information about Python and now let’s prepare our computer to develop software with Python:

We need an IDE to write and test our Python setup package and codes. We will do software development with Python on the Windows 10 Operating System. But you may be using a Linux Operating System or a Mac Operating System. Don’t worry, the method we’re going to use soon applies to all operating systems.

How to Download Python and Install Python

1. First of all, we visit the official website of Python Python.org. We’re switching to the Downloads page by clicking on the Downloads button. Here you can start the download for the latest version of Python based on your operating system. We are starting the download process for Windows with the Download Python button.

Python indirmek ve kurmak
Download and install from python web site

2. After the download is finished, we open our Python setup file. The first incoming setup window has another user account on your computer, and if it is to use Python, you’ll need to go to Customize Installation and set another location for Python setup. Windows users also activate the Add Python PATH option to add python to the environment variables of the directory to which it is installed. This allows you to run Python codes without going to the directory where Python is installed with Windows Command Prompt.

3. We are starting the installation with install now option.

4. We remove the previously defined 260 character limit on your computer with the Disable Path Length Limit option so that Python can run smoothly in the last window of Python setup.

5. We complete the Python setup process with the Close button.

Python indirmek ve kurmak
Python download and install

Hello World Python

There’s no need to break tradition. The first application written when learning each software language is to print “Hello World” Hello World to the screen.

Let’s first write the Python Hello World app with Windows Command Prompt. By opening the Start menu, we type cmd and press enter. In the Windows Command Prompt tool, we press enter by typing python. That’s how we switch to python development. As a code, we write this. When we press print (“Hello World”) and enter from the keyboard, we see hello world output on the screen.

Hyper-V Kurulumu-Hyper-V sistem gereksinimleri
Hyper-V Setup-Hyper-V system requirements

Second, let’s write the Python Hello World app with the Python IDLE tool. By opening the Start menu, we type idle and press enter, and we are greeted by the Python code development tool. Here’s what we write as code. Print(“Hello World”) and enter from the keyboard, we see hello world output on the Python Shell screen.

Python idle Hello World
Python idle Hello World

What is ide?

Our computer is ready to develop applications with python software language. But we have to have an app at our disposal so that we can diagnose, color our Python codes, show suggestions, find our mistakes, test them, and organize all our work files. In fact, this application should provide us with a working environment on the same project as our colleagues in different locations. These applications, which contain many features, can develop software quickly and seamlessly, called IDE programs. The IDE expansion can be done as an Integrated Development Environment. Python has written many IDE programs. We will develop your Python software with Pycharm IDE in our lessons.

What is Pycharm? How to Download Pycharm How to Install Pycharm?

What is Pycharm?

Pycharm is a powerful and easy-to-use IDE program that enables us to develop fast applications with Python software language that can work on Linux distributions, Mac Operating Systems, and Windows Operating Systems such as Ubuntu.

How to Download Pycharm?

To download the Pycharm IDE program, we visit the Pycharm subpage on the Official Website of JetBrains. https://www.jetbrains.com/pycharm/ download button.

After determining our choice according to our operating system, we see on this page that there are two different options called Pycharm Professional and Pycharm Community. I’d like to add an option when there are two options here. Pycharm Edu. Pycharm Professional comes with paid and many development plug-ins. Pycharm Community is completely free but lighter and simpler. As our trainings progress at the introduction and basic level, we will proceed with the Pycharm Community option. What about Pycharm Edu? Pycharm Edu is a free and open source tool that provides a powerful learning environment developed by focusing more on teacher and student relationships. If you previously installed Pycharm Professional or Pycharm Community on your computer, it is worth knowing that you have the chance to use it only by downloading the Pycharm EDU tool.

1. We are now starting pycharm download by clicking on the Download button under Pycharm Community option.

Python Pycharm indirmek
Python Pycharm download

How to Install Pycharm?

2. After pycharm download is complete, we open our downloaded file to start the Pycharm setup process. We’re moving forward with the next button.

3.We switch to the next window again using the Next button without changing the directory to which the program will be set up.

4. In the incoming setup options window, we can create a 32-bit or 64-bit Pycharm shortcut for the desktop with the options under the Create Desktop Shortcut tab. Pycharm setup is automatically installed as both 32 bits and 64 bits. With the option here, we only determine which version to create a shortcut for the desktop. We’re selecting the 64-bit option. If you lose the shortcut, you should know that you always have a chance to access pycharm 32-bit and Pycharm 64-bit versions under the C:\Program Files\JetBrains\PyCharm Community Edition xxx\bin folder.

By selecting Add launchers dir to the PATH under the Update PATH variable tab, we allow the Pycharm-installed directory to be added to the media variables.

Under the Update context menu tab By selecting Add “Open Folder as Project”, we have the ability to open it in the Pycharm program as a project by right-clicking on a folder. Under the Create Associations tab By selecting .py By clicking on the Python file with the .py extension, we have the ability to open directly with the Pycharm program. By selecting Download and Install JRE x86 by JetBrains, we allow the Pycharm program to install Java for smooth operation and We’re moving forward with the next button.

5. We start pycharm installation with the Install button without making any changes to the incoming window.

6. We are restarting our computer with the Finish button by selecting Reboot Now, and pycharm setup is thus complete.

Python Pycharm kurulumu
Python Pycharm setup

Pycharm First Opening and Pycharm Project Create

1. We can now create projects and develop software on our computer. I will manage all of our lessons under this folder by creating a folder as Python on the desktop. You can proceed the same way if you wish.

2. We open the Pycharm program by double-clicking on the shortcut. Since we don’t have specific settings for Pycharm before, we click ok button by selecting Do not import settings.

3.To help develop Pycharm, I prefer to send JetBrains my usage information with Send Usage Statistics. You’re free to move forward with any choice.

Pycharm ilk program açılışı ve ilk ayarları yapmak
Pycharm to open the first program and make the first settings

4. In the choice of user interface I prefer the dark one and click skip remaining and set defaults. You can still choose any of you.

Python Pycharm program açılışı
Python Pycharm program opening

5. An existing project with Open in the Pop-up Pycharm window can be opened but we are moving forward by clicking Create New Project to create a new project.

6. We click the folder mark in the Location area.

7. We select the Python folder that we create on the desktop.