🐍 Day 2 β€” Installing Python & Running Your First Code

Before we start writing Python programs, we need to set up our environment.

πŸ’» Step 1: Install Python
Download Python from the official website:
➑️ https://www.python.org/downloads
Make sure to check:
βœ” Add Python to PATH during installation (important!)

🧰 Step 2: Choose Where to Write Code
You can use any of the following:
βœ” IDLE (comes with Python)
βœ” VS Code (very popular)
βœ” PyCharm
βœ” Jupyter Notebook (for data science)
For beginners, VS Code or IDLE is perfect.
▢️ Step 3: Run Your First Python Code
Open your editor and type:
print("Hello, Python!")


If you see:
Hello, Python!


Congrats! 🀝 You just ran your first Python program.

πŸ“Œ Tip of the Day
Python uses indentation (spaces/tabs) instead of braces {} β€” so spacing matters!

πŸ“ Mini Task
Comment below:
Which editor are you using?

#negafantech
#python
#programming
#day2
🧩 Bonus Post: Interpreted vs Compiled Languages

When learning programming, you’ll often hear β€œinterpreted language” and β€œcompiled language.” Here’s the difference

πŸ‘‡

πŸ”Ή Compiled Language

A compiled language uses a compiler to translate the entire code into machine language before execution.


βœ”οΈ Faster execution
βœ”οΈ Errors detected at compile time
βœ”οΈ Produces an executable file

Examples: C, C++, Rust, Go

πŸ”Ή Interpreted Language

An interpreted language uses an interpreter to translate and run code line-by-line during execution.


βœ”οΈ Easier to test & debug
βœ”οΈ More flexible & portable
βœ–οΈ Usually slower than compiled languages

Examples: Python, JavaScript, Ruby, PHP

🧠 Key Insight

Compiled = β€œtranslated fully before running”
Interpreted = β€œtranslated as it runs”

🐍 Where does Python fit?

Python is generally considered an interpreted language, but internally it first compiles to bytecode (.pyc) and then the Python Virtual Machine interprets it. This is why Python is flexible and beginner-friendly.


πŸ’¬ Question for you

Which type do you think is better for beginners β€” compiled or interpreted?


Comment your thoughts! πŸ‘‡

YOUTUBE | TELEGRAM | TIKTOK
πŸ₯°1
🐍 Day 3 β€” Variables in Python

In Python, variables are used to store information so we can use it later in our program.
Think of a variable as a labeled box that holds data.

βœ” Creating a Variable
Example:
name = "Alice"
age = 21
pi = 3.14


Here:
"Alice" is a string
21 is an integer
3.14 is a float

Python automatically detects the type β€” no need to declare it manually.

βœ” Printing Variables

print(name)
print(age)


Output:

Alice
21


πŸ’‘ Why Variables Matter?
Variables make programs dynamic and flexible. You can change their values without changing the entire code.

🧩 Mini Task
Create two variables: your name and your favorite programming language, then print them.

Reply with your output! πŸ‘‡

#negafantech
#Python
#programming
#day3

πŸ’¬ Join the Telegram community πŸ”—
πŸŽ₯ Follow on TikTok πŸ”—
πŸ“Ί Watch on YouTube πŸ”—
Day 4 - Data Types in Python
🐍 Day 4 β€” Data Types in Python

In Python, every value has a data type. Data types tell Python what kind of data it is working with.


Here are some of the most common beginner-friendly types:
πŸ”Ή 1. String (str)
Used for text
name = "Alice"

πŸ”Ή 2. Integer (int)
Whole numbers
age = 20

πŸ”Ή 3. Float (float)
Decimal numbers
pi = 3.14

πŸ”Ή 4. Boolean (bool)
True or False values
is_student = True

πŸ”Ή 5. None Type
Represents no value
data = None


πŸ’‘ Why Data Types Matter?
βœ” Helps Python understand how to store and operate on data
βœ” Enables validation, calculations, decisions, and formatting
βœ” Makes your code logical and predictable


🧩 Mini Task

Create variables using at least 3 different data types and print them out.


Share your outputs below! πŸ‘‡

πŸ’¬ Join the Telegram community πŸ”—
πŸŽ₯ Follow on TikTok πŸ”—
πŸ“Ί Watch on YouTube πŸ”—
Negafan Tech pinned «🐍 Day 4 β€” Data Types in Python In Python, every value has a data type. Data types tell Python what kind of data it is working with. Here are some of the most common beginner-friendly types: πŸ”Ή 1. String (str) Used for text name = "Alice" πŸ”Ή 2. Integer (int)…»
πŸ“Day 5 β€” User Input in Python
πŸ“Day 5 β€” User Input in Python

Today we learn how programs interact with people!
The input() function allows users to enter data while the program is running.


🧩 How it Works
name = input("Enter your name: ")
print("Hello", name)



When you run this, Python waits for the user to type something.

πŸ” Important Point

Everything entered through input() is treated as text (string) by default.


So if you need numbers, you must convert them:

age = int(input("Enter your age: "))
print(age + 1)


🌟 Why User Input Matters

It helps you create dynamic programs like:
βœ”οΈ calculators
βœ”οΈ login systems
βœ”οΈ forms
βœ”οΈ interactive chatbots (πŸ‘€ like the one you're learning to build someday)


πŸ“ Mini Task

Ask the user for:

their name
their age
their country


Then print a sentence combining all three.

Drop your outputs! πŸ˜ŽπŸ‘‡

#day5
#python
#programming
#negafantech

πŸ’¬ Join the Telegram community πŸ”—
πŸŽ₯ Follow on TikTok πŸ”—
πŸ“Ί Watch on YouTube πŸ”—
Negafan Tech pinned Β«πŸ“Day 5 β€” User Input in Python Today we learn how programs interact with people! The input() function allows users to enter data while the program is running. 🧩 How it Works name = input("Enter your name: ") print("Hello", name) When you run this, Python…»
Quiz βœ…οΈ
Negafan Tech
Quiz
The solution is posted in the comment πŸ‘‡πŸ‘‡
πŸŽ‰ Question 1 Solution is Now Out! πŸŽ‰
πŸ‘‰ ASTU Python2 Final Exam Solutions

The video for ASTU Python Final Exam – Question 1 is now available!
πŸ”₯ Step-by-step explanation
πŸ”₯ Important points highlighted
πŸ”₯ Easy to follow

Watch it here: Q1 Solution
Make sure to watch, like, share, and subscribe to support the channel β€” more questions are coming! πŸš€

Stay tuned! πŸ’»πŸ“š

#python #astu #exam #solutions #negafantech
πŸŽ‰ Question on Dictionary Operations β€” Solution Video is Out! πŸŽ‰

We just uploaded the solution for the Python final exam question where we build a dictionary using a loop and store cubes of numbers! πŸ’»πŸ“š
If you're an ASTU freshman preparing for finals, don’t miss it β€” it’s explained step-by-step!
Make sure to Like, Share, and Subscribe to support the channel β€” more questions are coming! πŸš€

Watch it here
#python #astu #freshman #finalexam #solutions #negafantech
πŸŽ‰ ASTU Freshman β€” Python2 Final Exam Playlist is Here! πŸŽ“πŸ’»

Hey freshmen students!

The final exam is tomorrow! ⏰
I’ve created a complete Python2 ASTU Final Exam Solutions playlist with step-by-step walkthroughs of real exam questions. πŸ“βœ¨

πŸ‘‰ Check it out here

Boost your Python skills, and share with your friends so everyone is ready for tomorrow! πŸš€

#python #astu #freshman #finalexam #solutions #coding #programming #learnpython #negafantech
🐍 Day 6 β€” Type Conversion (Casting) in Python

When you receive input from users or work with different data types, sometimes you need to convert values β€” for example, from text to numbers.


This process is called type conversion or casting.


πŸ”§ Common Conversions


int()

β†’ converts to integer
float()

β†’ converts to decimal number
str()

β†’ converts to string
bool()

β†’ converts to True/False

βœ” Example

age = int(input("Enter your age: "))
print(age + 1)


Here, input() gives a string, so we convert it using int() to do math.

⚠ Important
If the value cannot be converted (e.g., "hello" β†’ int()), Python will raise an error.

πŸ“Œ Where Casting is Useful?
βœ” user input
βœ” math operations
βœ” formatting text
βœ” APIs & databases
βœ” data analysis

🧩 Mini Task
Ask for two numbers using input() and print their sum.


Tip: Convert them first πŸ˜‰