Python Getting Started
1. What is Python?
Python is a simple and powerful programming language.
It is easy to read and easy to write.
People use Python for:
-
Websites
-
Mobile and desktop apps
-
Data analysis
-
Artificial Intelligence (AI)
-
Automation (saving time)
π Python looks almost like normal English, so beginners love it.
2. Why Learn Python?
Python is popular because:
-
Easy to learn
-
Less code, more work
-
Used by big companies
-
Good for beginners and professionals
Example:
This single line can show text on the screen.
3. Installing Python
Step 1: Download Python
Go to the official Python website:
π https://www.python.org
Click Download Python.
Step 2: Install Python
During installation:
β Check βAdd Python to PATHβ
β Click Install Now
Step 3: Check Python Installation
Open Command Prompt (Windows) or Terminal (Mac/Linux)
Type:
If Python is installed, you will see the version number.
4. Running Your First Python Program
There are two easy ways to run Python.
Method 1: Using Python Interactive Mode
Open Command Prompt / Terminal
Type:
You will see something like:
Now type:
Output:
π This is called Interactive Mode.
It is good for testing small code.
Method 2: Using a Python File (Best Way)
Step 1: Create a File
Create a new file and name it:
Step 2: Write Code
Inside the file, write:
Step 3: Run the File
Open Command Prompt in the file location and type:
Output:
5. Understanding Your First Python Code
Explanation:
-
printβ shows output on the screen -
"Hello, World!"β text message -
()β used to pass data to print
6. Python Indentation (Very Important)
Python uses spaces, not { }.
Correct Example
Wrong Example
β This will give an error.
π Always use 4 spaces.
7. Python Comments
Comments are notes for humans.
Single-Line Comment
Multi-Line Comment
8. Python Variables (First Look)
Variables store values.
Print them:
9. Taking Input from User
Python can ask questions.
Input with Numbers
10. Your First Small Program
Program: Add Two Numbers
11. Common Beginner Mistakes
β Forgetting indentation
β Misspelling print
β Forgetting quotes for text
β Not converting input to number
Example mistake:
Correct:
12. Summary (Getting Started)
β Python is easy and powerful
β Can run Python in terminal or file
β print() shows output
β Spaces are important
β Input is text by default
π Perfect for eBook
This chapter is ideal for:
-
Beginner Python eBooks
-
School & college students
-
Self-learning readers
If you want next, I can write:
-
Python Syntax & Variables (Next Chapter)
-
Python in Bangla + English
-
Practice exercises with answers
-
MCQs for beginners
-
PDF / EPUB ready formatting
Just tell me π
