![]() | ![]() |
This practice exercise will utilize several concepts that we covered earlier.
a. Given the following program statement: Color1=’red’; color1=’blue’; CoLor1=’yellow’ explain why all the three will be treated as different variables in Python.
b. Consider the following Python program and identify what is wrong with it.
student1_age=23 #This is the age of the first student
student2_age=19 #This is the age of the student
sotal_age=student1_age +student2_age #Getting the sum of the ages of the
print(age) #Displaying their ages
c. Rewrite b. above to be a valid Python program