Phython
For this program you will be writing a program that will use if-else or if-elif-else statements.
Read-It-All bookstore has a book sales club where customers can earn reward points that can be used for their next purchase.
If a customer purchases 0 books, he/she earns 0 points.
If a customer purchases 1-3 books, he/she earns 5 points.
If a customer purchases 4-6 books, he/she earns 10 points.
If a customer purchases 7-8 books, he/she earns 15 points.
If a customer purchases 9 books, he/she earns 20 points.
If a customer purchases 10 or more books, he/she earns 25 points.
Write a program that asks the user to enter their name (First and last name), and the number of books that he or she has purchased this month and displays their name and the number of points they have earned for the month. Your program may run once per user, or may loop to accept multiple users.
name = input("Enter full name: ")
books = eval(input("Number of books purchased this month: "))
#customer purchases 0 books
if(books <= 0):
print(name,"earned 0 points")
#customer purchases 1-2 books
elif(books <= 2):
print(name, "earned 5 points")
#customer purchases 3-4 books
elif(books <= 4):
print(name, "earned 10 points")
# customer purchases 5-6 books
elif(books <= 6):
print(name, "earned 15 points")
#customer purchases 7-8 books
elif(books <= 8):
print(name, "earned 20 points")
#customer purchases 9 or more books
else:
print(name, "earned 25 points")


Phython For this program you will be writing a program that will use if-else or if-elif-else...
Python
11. Book Club Points Serendipity Booksellers has a book club that awards points to its customers based on the number of books purchased each month. The points are awarded as follows: If a customer purchases 0 books, he or she earns 0 points If a customer purchases 2 books, he or she earns 5 points. O If a customer purchases 4 books, he or she earns 15 points If a customer purchases 6 books, he or she earns 30...
Visual Studio and Visual Basic program
b. Serendipity Booksellers has a book club that awards points to its customers based on the number of books purchased each month. The points are awarded as follows: If a customer purchases no books, he or she earns 0 points. If a customer purchases 1 book, he or she earns 5 points. If a customer purchases 2 book, he or she earns 15 points. If a customer purchases 3 book, he or she earns...
Directions: Complete all the three programming assignments below. Please be sure to follow the programming rubric provided. Turn in three separate “.py" files. Be sure to run your programs before submission. Color Mixer The colors red, blue, and yellow are called primary colors, because they cannot be made by mixing other colors. When you mix two primary colors, you get a secondary color, as shown here: • When you mix red and blue, you get purple. • When you mix...
Code in c++ please
Q1: Software Sales A software company sells a package that retails for $99. Quantity discounts are given according to the following table: QuantityDiscount 10-19 20-49 50-99 100 or more 20% 30% 40% 50% : Write a program that asks for the number of units sold and computes the total cost of the purchase. Input validation: Make sure the number of units is greater than 0. Q2: Book Club Points Community Booksellers has a book club that...
Use python and use if, elif and else statements. Thank you! The program should first ask the user if they are a hero or a villain. If they enter “villain”, the program should ask them their name; if they enter “hero”, it should ask how many people they have saved, and respond to that information. Using decision structures, have your program execute certain print statements following these rules: If they enter that they are a villain Ask for their name...
python Programming. In this program you can use if, else and elif or list and dictionary. If your loaf of bread has passed its expiration date and has become stale or is smooshed/damaged, or your bread smells sour or has colored spots on it, then throw it out.
Hi,
Hi,
I need someone to write a program in Phython 3.6, and please I
will appreciate if the code is error free and indented correctly.
The output would be preferable.
thanks
Write a GUI program that translates the Latin words to English. The window should have three buttons, one for each Latin word. When the user clicks a button, the program displays the English translation in a label. 3. Miles Per Gallon Calculator Write a GUI program that calculates...
Topics If/Else statement Description Write a program that determines the larger of the two numbers provided by the user. The program asks the user to enter a number. Then it asks the user to enter another but a different number. Then, it determines the larger of the two numbers and displays it to the user. (If the user happens to enter the two numbers the same, the program may report either of the two numbers as larger.) Requirements Do...
Java: can also use “if else” statements Write a program that can convert an integer between 0 and 15 into hex number (including 0 and 15). The user enters an integer from the console and the program displays the corresponding hex number. If the user enters an integer out of range, the program displays a warning message about the invalid input. Table. Conversion between Decimal and Hexadecimal Decimal Hexadecimal 0 0 1 1 2 2 3 3 4 4 5...
write a c++ program :Assume one of the companies is renting flats for people asks you to develop a small system to help them track who paid the rent fees, and who did not for the coming month. The data in this system includes: ID number of the person who rented the house, flat number , fine to be paid, tenant name, status of payment(paid or unpaid ). The main interface of the system should be as follows: 1- Add...