1. Introduction & Setup
Installing Python 3: Instructions on setting up Python on your machine.
Your First Python Program: Writing a simple “Hello, World!” program to understand the basics.
2. Python Basics
Variables & Input Handling:
o Variables store data, e.g., name = "Alice".
o Receiving user input using the input() function.
Data Types and Type Conversion:
o Integers, strings, floats, and booleans.
o Conversion functions like int(), float(), and str().
3. Strings & Operations
String Methods: Operations like .upper(), .lower(), and .find().
Formatted Strings: Embedding variables within strings using f-strings:
Example: f"My name is {name}".
Math Operations:
o Basic arithmetic: +, -, *, /.
o Operator precedence and built-in math functions (round(), abs()).
4. Control Flow
Conditional Statements:
o Using if, elif, and else for decision-making.
o Example: Checking age for voting eligibility.
Loops:
o While Loops: Run as long as a condition is true.
o For Loops: Iterate over a sequence (like a list).
Guessing Game Project: A small interactive game using loops.
5. Functions & Error Handling
Creating Functions:
o Defining reusable functions with def.
o Passing arguments and using return statements.
Handling Errors with Try-Except: Managing exceptions gracefully.
Installing Python 3: Instructions on setting up Python on your machine.
Your First Python Program: Writing a simple “Hello, World!” program to understand the basics.
2. Python Basics
Variables & Input Handling:
o Variables store data, e.g., name = "Alice".
o Receiving user input using the input() function.
Data Types and Type Conversion:
o Integers, strings, floats, and booleans.
o Conversion functions like int(), float(), and str().
3. Strings & Operations
String Methods: Operations like .upper(), .lower(), and .find().
Formatted Strings: Embedding variables within strings using f-strings:
Example: f"My name is {name}".
Math Operations:
o Basic arithmetic: +, -, *, /.
o Operator precedence and built-in math functions (round(), abs()).
4. Control Flow
Conditional Statements:
o Using if, elif, and else for decision-making.
o Example: Checking age for voting eligibility.
Loops:
o While Loops: Run as long as a condition is true.
o For Loops: Iterate over a sequence (like a list).
Guessing Game Project: A small interactive game using loops.
5. Functions & Error Handling
Creating Functions:
o Defining reusable functions with def.
o Passing arguments and using return statements.
Handling Errors with Try-Except: Managing exceptions gracefully.