File tree 4 files changed +39
-0
lines changed
4 files changed +39
-0
lines changed Original file line number Diff line number Diff line change
1
+ # Day 1: Python Basics
2
+
3
+ ## What You'll Learn:
4
+ - Basic program structure
5
+ - Printing to console
6
+ - Variable declaration
7
+ - User input handling
8
+
9
+ ## Files:
10
+ 1 . ` hello_world.py ` - Basic print statement
11
+ 2 . ` variables.py ` - Variable usage examples
12
+ 3 . ` user_input.py ` - Getting and using user input
13
+
14
+ ## Exercises:
15
+ 1 . Create a program that asks for your name and age, then prints them
16
+ 2 . Make a currency converter from USD to EUR (hardcode rate)
Original file line number Diff line number Diff line change
1
+ # Simple print statement
2
+ print ("Hello World!" )
3
+
4
+ # Multi-line print
5
+ print ("""This is
6
+ a multi-line
7
+ string""" )
Original file line number Diff line number Diff line change
1
+ # Basic input
2
+ name = input ("Enter your name: " )
3
+ print (f"Hello, { name } !" )
4
+
5
+ # Numeric input
6
+ age = int (input ("Enter your age: " ))
7
+ print (f"You'll be { age + 5 } in 5 years" )
Original file line number Diff line number Diff line change
1
+ # Variable declaration
2
+ name = "James"
3
+ age = 25
4
+ height = 1.75
5
+ is_student = True
6
+
7
+ # Formatted string
8
+ print (f"{ name } is { age } years old" )
9
+ print (f"Type of age: { type (age )} " )
You can’t perform that action at this time.
0 commit comments