コード例 #1
0
                  "\n\n")
        elif choice == 2:
            price = float(input("What would you like the new price to be?"))
            book2.price = price
            print("The price has been changed to" + ' ' + str(book2.price) +
                  "\n\n")

    elif menu_choice == 4:
        print("Book 1 or 2?")
        choice = int(input())
        if choice == 1:
            year = int(
                input(
                    "What year would you like to change it to, can be past or future."
                ))
            book1.year = year
            print("The year that" + ' ' + book1.title + ' ' +
                  "came out is actually" + ' ' + str(book1.year) + "\n\n")
        elif choice == 2:
            year = int(
                input(
                    "What year would you like to change it to, can be past or future."
                ))
            book2.year = year
            print("The year that" + ' ' + book2.title + ' ' +
                  "came out is actually" + ' ' + str(book2.year) + "\n\n")

    elif menu_choice == 5:
        print("Thank you for your input, have a great day!")
    else:
        print("Error, choose from the menu above!")