print("Hello, World!")name = "Sree"
age = 25
height = 5.9
is_student = True
print(name, age, height, is_student)int, float, str, bool.user_name = input("Enter your name: ")
print("Welcome,", user_name)Hello John, you will be 30 in 5 years.# Arithmetic
a, b = 10, 3
print(a + b, a - b, a * b, a / b, a % b)
# Comparison
print(a > b, a == b, a != b)
# Logical
x, y = True, False
print(x and y, x or y, not x)text = "Python Basics"
print(text.upper())
print(text.lower())
print(text[0:6]) # slicing
print("Basics" in text) # membership# List
fruits = ["apple", "banana", "cherry"]
fruits.append("orange")
print(fruits)
# Tuple (immutable)
coordinates = (10, 20)
# Set (unique values)
numbers = {1, 2, 2, 3}
print(numbers)
# Dictionary (key-value)
student = {"name": "Alice", "age": 20}
print(student["name"])age = int(input("Enter your age: "))
if age >= 18:
print("You are an adult")
else:
print("You are a minor")# For loop
for i in range(5):
print("Iteration", i)
# While loop
count = 0
while count < 5:
print("Count:", count)
count += 1for i in range(10):
if i == 5:
break # stop loop
if i % 2 == 0:
continue # skip even numbers
print(i)import random
secret = random.randint(1, 10)
guess = int(input("Guess a number (1-10): "))
if guess == secret:
print("Correct! π")
else:
print("Wrong, the number was", secret)def greet(name):
return "Hello " + name
print(greet("Sree"))x = 10
def func():
x = 20 # local
print("Inside:", x)
func()
print("Outside:", x)try:
num = int(input("Enter a number: "))
print("You entered", num)
except ValueError:
print("Invalid input! Please enter a number.")import random
choices = ["rock", "paper", "scissors"]
user = input("Choose rock/paper/scissors: ").lower()
computer = random.choice(choices)
print("Computer chose:", computer)
if user == computer:
print("It's a tie!")
elif (user == "rock" and computer == "scissors") or \
(user == "paper" and computer == "rock") or \
(user == "scissors" and computer == "paper"):
print("You win! π")
else:
print("You lose! π’")By the end of Month 1, interns will:
Perfect β Hereβs a Weekly Assignment Sheet for Month 1 (Python Basics), designed for freshers with zero coding skills. Each week includes progressive assignments, ending with a mini project.
Objective: Get comfortable with writing and running Python programs.
Assignments:
print("Hello World").Mini Project: π Future Age Calculator
"Hello John, you will be 30 in 5 years."Objective: Learn to store and manipulate data.
Assignments:
Take a sentence input and print:
"Python" exists in it.Create a list of 5 fruits. Add a new fruit and remove one.
Create a dictionary with keys name, age, city and print values.
Mini Project: π Shopping List Manager
Objective: Learn to make decisions and repeat actions.
Assignments:
Mini Project: π Number Guessing Game
Objective: Organize code into reusable blocks, handle errors gracefully.
Assignments:
add(a, b) that returns the sum of two numbers.greet(name) that prints "Hello, <name>"."abc" when asked for a number).Mini Project: π Rock-Paper-Scissors Game
Perfect β hereβs a Grading Rubric for Month 1 (Python Basics). It uses 3 levels (Beginner β Intermediate β Pro) with clear criteria for each weekβs skills. This way, you can track progress, evaluate fairly, and give feedback.
| Level | Criteria |
|---|---|
| Beginner (β ) | Installed Python but struggles to run scripts, only reproduces copy-paste code without understanding. |
| Intermediate (β β ) | Successfully writes print, variables, and input/output programs. Understands basic data types. |
| Pro (β β β ) | Writes clean scripts with meaningful variable names, comments, and completes Future Age Calculator independently. |
| Level | Criteria |
|---|---|
| Beginner (β ) | Can store data in lists/strings but struggles with modifying or accessing them. |
| Intermediate (β β ) | Can manipulate strings, lists, dictionaries, and complete Shopping List Manager with little help. |
| Pro (β β β ) | Demonstrates creativity (e.g., sorting items, preventing duplicates), uses multiple collection types effectively. |
| Level | Criteria |
|---|---|
| Beginner (β ) | Understands if statements but struggles with loops. Code may have errors or infinite loops. |
| Intermediate (β β ) | Correctly uses if/else, for, and while loops. Completes Number Guessing Game with hints. |
| Pro (β β β ) | Uses nested conditions/loops, adds replay option in Number Guessing Game, writes clear, structured code. |
| Level | Criteria |
|---|---|
| Beginner (β ) | Can call simple functions but struggles with parameters and return values. Limited error handling. |
| Intermediate (β β ) | Defines reusable functions, uses try/except for handling invalid inputs. Completes Rock-Paper-Scissors. |
| Pro (β β β ) | Modularizes the game into multiple functions, adds score tracking (best of 3), and handles invalid inputs gracefully. |
π Suggested Weightage:
π‘ By the end of Month 1, interns who reach Intermediate (β β ) are ready for Month 2 (Docker + Web Dev). Those at Pro (β β β ) can already start guiding peers.