Skip to main content

Python Tutorial - Basics

Python is used across different organizations and utilized for multiple projects across the world. It's very easy to learn, maintain, and update. It is open-source, available for free, and supports multiple projects as well. It can be used for scripting in the background, creating wonderful programs, and also can be used for processing complex items like Natural Language Processing, Medical Image Processing, or even more complex items. 

Python Logo

The good thing about Python is easy to Learn. Effective to use, and moreover less number of lines of code. It's just like writing it in plain English and less number of brackets but uses the power of the indentation.  

This post will have some steps, to begin with. like installing, IDE setup, printing, reading the inputs, and variables declaration. 

Installation:

To install python, go to the official website and download it on your computer. You can install it on any operating system. If you prefer to run online IDE, there are so many good websites available.

I personally prefer, https://colab.research.google.com/. They provide free GPU and TPU features, which will be used for processing huge data in a short time. We will discuss this in feature posts. 

There are so many IDEs available for Python execution, including the official IDE from python. Spyder, Jupyter Notebook, and PyCharm are some of the famous IDEs which is supported in multiple operating systems.

MS Visual studio code and Notepad++ are also used by some developers. 

For beginners and basic usage, I would recommend using the python IDE that comes by default. Once you understand the basics, then you can try out plenty of options available for free and select your own. 

I am going to use MS Visual studio code later in the posts since it has the GitHub Pilot option and Git Integration. 

Printing:

To print something, we can use the simple command "print".

print ("Hello World!")

Print Hello World in Python

If you are going to use MS Visual studio code, then it will look like this,


print ("Hello World!")


Popular posts from this blog

Building an Art Gallery Program in Python

Building an Art Gallery Program in Python As an art lover, you may have considered creating a program to manage your favorite art pieces and display them in a virtual art gallery. This program can help you keep track of the details of each piece, including the image, description, and price. In this article, we will go through the process of building an art gallery program using Python and several libraries, including Tkinter, Pillow, and Pandas. Importing Necessary Libraries Before we start building our program, we need to import the libraries that we will be using. Tkinter will be used for creating the GUI, Pillow for handling image processing, and Pandas for data management. Creating the Art Gallery Class Next, we create a class for the art gallery program and initialize the necessary variables, such as the list of art pieces, their images, descriptions, and prices. We will also define the main window and its features, such as buttons for adding, editing, and removing art pieces, and...

Creating a Media Player in Python: Using Tkinter and Pygame to Control and Play MP3 and MP4 files

Creating a Media Player in Python: Using Tkinter and Pygame to Control and Play MP3 and MP4 files A media player program in Python using the Tkinter library for the GUI and the Pygame library for playing audio and video files:  Import statements: The program first imports the required libraries - tkinter as tk, filedialog, and messagebox from tkinter, and pygame. GUI setup: The Tk() method is used to create the main window of the application, and its title and dimensions are set using the title() and geometry() methods. Pygame initialization: The Pygame library is initialized using the pygame.init() method. Function definitions: The program defines several functions that perform different actions in the media player, such as browse_file() which opens a file dialog to select a file, play_file() which plays the selected file using Pygame's mixer module, pause_file() which pauses the playing file, resume_file() which resumes the playing file, stop_file() which stops the playing file, ...

How to Create a Simple Budget Calculator Using Python?

Are you looking for an easy and efficient way to keep track of your finances?  Look no further than this tutorial on how to create a simple budget calculator using the Python programming language. Introduction Python is a versatile and user-friendly programming language that can be used for a wide range of applications, including budgeting. This tutorial will walk you through the process of creating a simple budget calculator that allows you to input your income and expenses, and calculate your total income and expenses. Materials To follow along with this tutorial, you will need the following: A computer with a Python development environment set up (such as IDLE or PyCharm) Basic knowledge of Python programming concepts, such as variables, loops, and functions Creating the Budget Calculator How to Create a Simple Budget Calculator Using Python? The first step in creating the budget calculator is to define the income and expense functions. In the code provided, the income function ...

A Simple Address Book Program in Python with GUI

A Simple Address Book Program in Python with GUI An address book is a collection of contact information for individuals and organizations. This information can include names, addresses, phone numbers, email addresses, and other details. A program that allows you to manage your address book is a great tool for keeping track of your contacts. In this article, we'll show you how to create a simple address book program in Python and display the GUI using the required libraries. In this article, we will be covering how to create a simple address book program in Python with a GUI. The GUI (graphical user interface) is built using the tkinter library in Python, which is the standard GUI library for Python. The address book program allows you to add contacts, view contacts, and store their information such as name, phone number, email, and address. The program uses tkinter widgets such as Entry, Text, Button, Label, and Listbox to build the interface. Before diving into the code, let's...

Are you interested in learning SQL but don't know where to start?

Are you interested in learning SQL but don't know where to start?  Look no further than "The SQL Journey ," now available on Amazon Kindle and Google Play books store. This eBook is designed for anyone above 5th grade to learn and understand SQL. Cover page of "The SQL Journey" by Mythili Mohan SQL, or Structured Query Language, is a crucial skill for roles like Data Analysts . It allows users to manage and manipulate data stored in relational databases. By mastering SQL, you can gain valuable skills that are highly sought after in today's job market. "The SQL Journey" is a comprehensive guide that covers everything from the basics of SQL. Each chapter is filled with practical examples which are easy to understand. SQL Logo Whether you're a student, a working professional, or just someone who wants to learn a valuable skill, "The SQL Journey" is the perfect resource. It's easy to read, jargon-free, and accessible to anyone with ...