Python Ratings Comparison

Your goal is to write a program that compares two things and make a recommendation based on which rating or score is higher.

In my example, I used movies and Rotten Tomatoes ratings. You can use cars, pitchers, restaurants, etc. Movies are fine as well.

Requirements:

  1. write the program yourself. Do not use AI or another person’s code.
  2. make sure that all variables match the subject of your program. If you are comparing movies your variables wouldn’t be car1name and car2name.
  3. ask for the person’s name.
  4. use their name twice in the program.
  5. ask for the name of the first item.
    HINT: movie1title=input(f”{name}, what is the title of your first movie choice?”)
  6. ask for the rating of the first item by using the first item’s name. Like: “What is the Rotten Tomatoes rating for Star Wars?”
  7. ask for the name of the second item.
  8. ask for the rating of the second item by using the second item’s name. Like: “What is the Rotten Tomatoes rating for War Games?”
  9. calculate the difference between each rating.
    HINT: use abs like this:
    difference = abs(movie1rating-movie2rating)
    using abs guarantees a positive number as a result
  10. use comparison operators to compare the scores or ratings of the two items.
  11. print a recommendation based on highest score. Your recommendation should include:
    -the name of the highest rated item
    -the difference between the two scores or ratings
    -the name of the second item
    Like this:
  12. variables needed:
    name of person
    name of first item
    rating of first item
    name of second item
    rating of second item
    difference between rating of item 1 and item 2
    HINT: use abs like this:
    difference = abs(movie1rating-movie2rating)
    using abs guarantees a positive number as a resultfinal output sample: