#Q1 Fix all the syntax and logical errors in the given source code 
#add comments to explain your reasoning

# This program gets three test scores and displays their average.  It congratulates the user if the 
# average is a high score. The high score variable holds the value that is considered a high score.

HIGH_SCORE = 95
 
# Get the test scores.
test1 = int(input('Enter the score for test 1: '))
test2 = int(input('Enter the score for test 2: '))
test3 = int(input('Enter the score for test 3: '))
# Calculate the average test score.
average = (test1 + test2 + test3) / 3
# Print the average.
print('The average score is', average)
# If the average is a high score,
# congratulate the user.
if average >= HIGH_SCORE :
    print('Congratulations!')
else:
    print('That is a great average!')
#Q2
#The area of a rectangle is the rectangle’s length times its width. Write a program that asks for the length and width of two rectangles and prints to the user the area of both rectangles. 

length1 = float(input("Enter the length of the first rectangle: "))
width1 = float(input("Enter the width of the first rectangle: "))

# Calculate the area of the first rectangle
area1 = length1 * width1
# Get the dimensions of the second rectangle (length and width)
length2 = float(input("Enter the length of the second rectangle: "))
width2 = float(input("Enter the width of the second rectangle: "))

# Calculate the area of the second rectangle
area2 = length2 * width2

# Print the areas of both rectangles
print(f"The area of the first rectangle is {area1} square units.")
print(f"The area of the second rectangle is {area2} square units.")
#Q3 
#Ask a user to enter their first name and their age and assign it to the variables name and age. 
#The variable name should be a string and the variable age should be an int.  

#Using the variables name and age, print a message to the user stating something along the lines of:
# "Happy birthday, name!  You are age years old today!"

# This program asks for the user's name and age, and prints a birthday message.

# Get the user's first name and age
name = input("Enter your first name: ")  # name is a string by default
age = int(input("Enter your age: "))  # age should be an integer

# Print a message using the user's name and age
print(f"Happy birthday, {name}! You are {age} years old today!")