Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
194c8fa
add warmup2.py
genesisjzm-rgb Jul 14, 2026
cd37436
add warmup3.py
genesisjzm-rgb Jul 15, 2026
4ab4081
add warmup4.py
genesisjzm-rgb Jul 15, 2026
2d13446
add mini_project.py
genesisjzm-rgb Jul 15, 2026
54b759a
add warmup1.py
genesisjzm-rgb Jul 15, 2026
baf23b1
add warmup1.py
genesisjzm-rgb Jul 21, 2026
9ac9efa
add warmup2.py
genesisjzm-rgb Jul 21, 2026
5fa6bd5
add warmup3.py
genesisjzm-rgb Jul 21, 2026
ddf1940
add warmup4.py
genesisjzm-rgb Jul 21, 2026
cac6c53
add mini_project.py
genesisjzm-rgb Jul 21, 2026
6922c1a
add warmup1.py
genesisjzm-rgb Jul 21, 2026
6579456
add warmup2.py
genesisjzm-rgb Jul 21, 2026
fd35516
add warmup3.py
genesisjzm-rgb Jul 21, 2026
9a0219c
add warmup4.py
genesisjzm-rgb Jul 21, 2026
543059c
add warmup1.py
genesisjzm-rgb Jul 22, 2026
1b75392
add warmup2.py
genesisjzm-rgb Jul 23, 2026
28bb535
add warmup3.py
genesisjzm-rgb Jul 23, 2026
06d7998
add warmup4.py
genesisjzm-rgb Jul 23, 2026
6eebc4e
add mini_project.py
genesisjzm-rgb Jul 23, 2026
5b3d934
updated warmup1.py
genesisjzm-rgb Jul 26, 2026
5cbb1e5
updated warmup2.py
genesisjzm-rgb Jul 26, 2026
b33614c
updated warmup4.py
genesisjzm-rgb Jul 26, 2026
d239725
updated mini_project.py
genesisjzm-rgb Jul 26, 2026
6277559
added warmup1.py
genesisjzm-rgb Jul 28, 2026
91fbc06
added warmup2.py
genesisjzm-rgb Jul 28, 2026
62ad1c7
added warmup3.py
genesisjzm-rgb Jul 28, 2026
fd49295
finish warmups and mini project
genesisjzm-rgb Jul 28, 2026
ce00279
added warmup1.py
genesisjzm-rgb Aug 4, 2026
310a8f1
added warmup2.py
genesisjzm-rgb Aug 4, 2026
eb6759d
added warmup3.py
genesisjzm-rgb Aug 5, 2026
3fe0a06
added warmup4.py
genesisjzm-rgb Aug 5, 2026
c7cae7c
added mini_project.py
genesisjzm-rgb Aug 5, 2026
4625e64
added warmup1.py
genesisjzm-rgb Aug 11, 2026
a83c093
added warmup2.py
genesisjzm-rgb Aug 11, 2026
060e260
added warmup3.py
genesisjzm-rgb Aug 11, 2026
b973c3e
added warmup4.py
genesisjzm-rgb Aug 11, 2026
6e2f6ec
mini_project.py
genesisjzm-rgb Aug 11, 2026
af972d1
added warmup1.py
genesisjzm-rgb Aug 18, 2026
8c52ee6
added warmup2.py
genesisjzm-rgb Aug 18, 2026
8272fa1
added warmup3.py
genesisjzm-rgb Aug 18, 2026
88f204d
added warmup4.py
genesisjzm-rgb Aug 18, 2026
fd4b98c
added mini_project.py
genesisjzm-rgb Aug 18, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions week-2/assignment-2/mini_project.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
fahrenheit = float(input("Enter a temperature in Fahrenheit:"))

celcius = (fahrenheit - 32) * 5 / 9

print(f'{fahrenheit:.1f}°F is {celcius:.1f}°C.')



3 changes: 3 additions & 0 deletions week-2/assignment-2/warmup1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
print ('Python is working!')


10 changes: 10 additions & 0 deletions week-2/assignment-2/warmup2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#navigations commands I used:
# cd python-intro-homework
#ls
#cd week-2
#cd assignment-2
#pwd


date = input("What is today's date? ")
print(f'You said today is {date}.')
7 changes: 7 additions & 0 deletions week-2/assignment-2/warmup3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# git log --oneline output:
# 194c8fa add warmup2.py
# 294742d add week 2 folder
# 58d836d Add files via upload
# d8c0c05 Update README.md

print("This week I learned how to use Python input, work with strings, and run Git commands in the terminal!")
16 changes: 16 additions & 0 deletions week-2/assignment-2/warmup4.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@

# 1. What the error message said:
# NameError: name 'naame' is not defined. Did you mean: 'name'?

#2. What caused it:
# I misspelled the variable name as 'naame' inside the print statement
# and forgot to include input() on line 1, so Python didn't know what 'naame' was.

#3. How I fixed it:
# I added input() to line 1 to capture the user's input and corrected
# the spelling of the variable to 'name' in the print statement.'''

# Fixed, working code:

name = input("What is your name? ")
print(f"Your name is {name}.")
33 changes: 33 additions & 0 deletions week-3/assignment-3/mini_project.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
day = input('Please enter a day of the week: ').strip().lower()
time_of_day = input("Please enter a time of day (morning, afternoon, or evening): ").strip().lower()

if day == "monday":
if time_of_day == "morning":
print("Activity: Go for an early morning walk!! ")
elif time_of_day == "afternoon":
print('Activity: Make yourself a yummy snack!! ')
elif time_of_day == "evening":
print('Activity: Make yourself a yummy and healthy dinner')
else:
print('Invalid time of day')
elif day == "saturday":
if time_of_day == "morning":
print('Activity: Make yourself a nice cup of coffee to start your day!!')
elif time_of_day == "afternoon":
print('Activity: Spend your afternoon in a park or somewhere outdoors')
elif time_of_day == "evening":
print('Activity: Go and have nice dinner with a special someone')
else:
print('Invalid time of day')
elif day == "sunday":
if time_of_day == "morning":
print('Activity: Visit a local farmers market!!')
elif time_of_day == "afternoon":
print('Activity: Visit family or friends')
elif time_of_day == "evening":
print('Activity: Movie night!!')
else:
print('Invalid time of day')
else:
print('Invalid day of the week. Please choose Monday, Saturday, or Sunday!')

20 changes: 20 additions & 0 deletions week-3/assignment-3/warmup1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
score = 100
if score >= 90:
grade = 'A'
elif score >= 80:
grade = 'B'
elif score >= 70:
grade = 'C'
elif score >= 60:
grade = 'D'
else:
grade = 'F'

print(f'Score: {score}')
print(f'Grade: {grade}')






13 changes: 13 additions & 0 deletions week-3/assignment-3/warmup2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
age = int(input('What is your age '))

if age >=0 and age <= 12:
print('You are a Child. ')
elif age >= 13 and age <= 17:
print(' You are a Teen. ')
elif age >= 18 and age <= 64:
print(' You are an Adult. ')
elif age >= 65:
print('You are a Senior')
else:
print('Invalid Age')

14 changes: 14 additions & 0 deletions week-3/assignment-3/warmup3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# 'not True' is False and since one side is False False and False gives False
print(not True and False)

# 'True or False' only needs one to ne True so it gives True
print(True or False and False)

# 5 is greater than 3 so thats True and adding not flips True to False so its False.
print(not (5 > 3))

# 10 equals 10 is true, but 4 not equal to 4 is False. Both arent True 'and' gives False
print(10 == 10 and 4 != 4)

# 'not False' is True, and 'not True' is False. It gives True
print(not False or not True)
16 changes: 16 additions & 0 deletions week-3/assignment-3/warmup4.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
number = int(input('Enter a number: '))

if number > 0:
print(f'{number} is positive.')
elif number < 0:
print(f'{number} is negative.')
else:
print(f'{number} is zero. ')



if number % 2 == 0:
print(f'{number} is even. ')

else:
print(f'{number} is odd.')
36 changes: 36 additions & 0 deletions week-4/assignment-4/mini_project.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
students = [
{"name": "Jazmine", "score": 88, "subject": "Python"},
{"name": "Luis", "score": 74, "subject": "Data"},
{"name": "Sara", "score": 91, "subject": "Python"},
{"name": "Marcus", "score": 68, "subject": "Web"},
{"name": "Priya", "score": 95, "subject": "Data"},
{"name": "Devon", "score": 72, "subject": "Python"},
{"name": "Mia", "score": 83, "subject": "Web"},
{"name": "Eli", "score": 79, "subject": "Data"},
]

highest_score = 0
top_scorer_name = ""
total = 0
subject = set()
high_scorers = []

for student in students:
if student["score"] > highest_score:
highest_score = student["score"]
top_scorer_name = student["name"]

total += student["score"]


subject.add(student["subject"])

if student["score"] > 75:
high_scorers.append(student["name"])

average = total / len(students)

print(f"Top scorer: {top_scorer_name} ({highest_score})")
print(f"Class average: {average}")
print(f"Subjects offered: {subject}")

13 changes: 13 additions & 0 deletions week-4/assignment-4/warmup1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
num = ["2", "4", "6", "8", "10", "12", "14", "16"]

#first item
print(num[0])

#last item(negative index)
print(num[-1])

##slice, only the middle four numbers
print(num[2:6])
#the full list in reverse
num.reverse()
print(num)
10 changes: 10 additions & 0 deletions week-4/assignment-4/warmup2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
student = {"name": "Genesis",
"Grade": "B",
'subjects': ["english", "math", "history"]}

for key, value in student.items():
print(f"{key}: {value}")

student["graduated"] = False

print(student)
9 changes: 9 additions & 0 deletions week-4/assignment-4/warmup3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
list1 = ["Python", "Java", "C++", "Javascript"]
list2 = ["HTML", "CSS", "Bash Script", "Javascript"]

set1 = set(list1)
set2 = set(list2)

print(set1.union(set2))
print(set1.intersection(set2))
print(set1.difference(set2))
59 changes: 59 additions & 0 deletions week-5/assignment-5/mini_project.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
numbers = [42, 17, 83, 5, 61, 29, 74, 8, 55, 93, 31, 66, 14, 47, 78, 3, 59, 22, 86, 40]

def show_menu():
print('=== Number Cruncher ===')
print('1. Find the minimum number')
print('2. Find the maximum number')
print('3. Search for a number')
print('4. Sort the list')
print('5. Quit')


running = True
while running:
show_menu()
choice = input("\nEnter your choice: ")

##user input validation

if choice == '1':
min_number = numbers[0]
for number in numbers:
if number < min_number:
min_number = number
print(f'The minimum number is: {min_number}')

elif choice == '2':
max_number = numbers[0]
for number in numbers:
if number > max_number:
max_number = number
print(f'The maximum number is: {max_number}')

elif choice == '3':
search = input("Enter a number to search for: ")
found = False #this is set to keep track of if its found or not

#this is to loop through every index of the list to find the number

for i in range(len(numbers)):
if numbers[i] == search:
print(f'Found {search} at index {i}.')
found = True
break
if not found:
print(f'{search} was not found in the list.')

##This is bubble sort without .sort() or sorted()
elif choice == '4':

for i in range(len(numbers)):
for j in range(0, len(numbers) - i - 1):
if numbers[j] > numbers[j + 1]:
numbers[j], numbers[j + 1] = numbers[j + 1], numbers[j]
print(f'The sorted list is: {numbers}')
elif choice == '5':
print('Goodbye!')
running = False
else:
print('Invalid choice. Please try again.')
5 changes: 5 additions & 0 deletions week-5/assignment-5/warmup1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

total = 0
for number in range(1,101):
total += number
print(f'The sum of 1 to 100 is: {total} ')
16 changes: 16 additions & 0 deletions week-5/assignment-5/warmup2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@

while True:

try:
user_in = input('Please enter a number: ')
if user_in.isdigit():
number = int(user_in)
break
else:
print("That's not a positive integer. Try again.")

except ValueError:

print("That's not a positive integer. Try again.")

print(f'Got it: {number}')
14 changes: 14 additions & 0 deletions week-5/assignment-5/warmup3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name = ["Genesis", "John", "Alice", "Bob", "Mary", "Jane", "Tom", "Jerry", "Sam", "Lucy"]

find = input("Enter a name to find: ")

counter = 0

for n in name:
if n == find:
print(f" Found {find} at index {counter}.")
else:
counter += 1

if counter == len(name):
print(f"{find} is not in the list.")
10 changes: 10 additions & 0 deletions week-5/assignment-5/warmup4.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@

for number in range(1, 31):
if number % 3 == 0 and number % 5 == 0:
print("FizzBuzz")
elif number % 3 == 0:
print("Fizz")
elif number % 5 == 0:
print("Buzz")
else:
print(number)
Loading