Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please help me with objective five. I mostly need the explanation rather than just the code! thank you for being understanding and I appreciate your
please help me with objective five. I mostly need the explanation rather than just the code! thank you for being understanding and I appreciate your work :)
Problem Overview Your task in this homework assignment is to welle a program that outputs the factorial of a given non negative neger. Recal that the factorial of a number in the product of pooltive Integers from 1 up to and including That is: Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use input and print to get data from user and display output. 2. You must use a for loop to assist in computing the factorial 3. You must format your code using the Format Document command in your development erveronment 4. You must produce output exactly as shown below, assuming the given user inputs. Enter the value for which you wish to find the factorial: -10 Error Factorial does not exist for negative numbers. Enter the value for which you wish to find the factorial: S 51 - 120 CPTR 141: Objective #5 (1 point) Problem Overview Your task in this homework assignment is to write a program that outputs the characters that come before a given character in the alphabet in reverse order. Note that only lower-case characters should be listed Solution Specifications Your solution to this problem must meet the following alterla. 1. You must use input and print to get data from user and display output 2. You may wish to use ord() and/or char() to convert between unicode numbers and character. 3. You must format your code using the "Format Document command in your development environment. 4. You must produce output exactly as shown below if the user enteredy. Enter a letter in the alphabet: y Listing Backwards: y*wvutsrepo Grade Specification You will earn one point for completion of this homework problem once your solution passes al Submitty tests indicated by a green bars) Submitty Grader Cerminal Help Preview README.md x CPTR 141: Objective #5 (1 point) Problem Overview Four task in this homework assignment is to write a program that finds the Indexes of all occurrences of a given character within a given string Treat UPPER and LOWER case characters as if they were the same. Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use input and print to get data from user and display output. 2. You may use a foror while to iterate over given string. 3. You must format your code using the "Format Document command in your development environment. 4. You must produce output exactly as shown below when the company names "Matija, and are entered. Enter a string: Matija Enter the character to search for: a The character "a" appears at Indexes (1, 5). CPTR 141: Objective #5 (1 point) Problem Overview Your task in this homework assignment is to write a program that prompto the user for a madrum price, and then prints all menu kems from a pre-defined dictionary that cost that puch or less. Solution Specifications Your solution to this problem must meet the following catteria. 1. You must use print to display output 2. You must use the dictionarysoudishes found in the menu module to get the menu lerns. 3. You must format your code using the Format Document command in your development endronment. 4. You must produce output exactly as shown below. - PTR 141 Restaurant Welcome Tell me how much you want to spend and I'll tell you what we have. What is your budget? $18 You can get: Pumpkin pie for $6.99 10-pc Nuggets for $3.99 Burger Sliders for $8.99 Breadsticks for $1.99 Aanana Pancakes for $6.99 a Proview README.md Preview README.md CPTR 141: Objective #5 (1 point) Problem Overview Your task in this homework assignment is to write a program that outputs each character of a string separated by a character. Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use print to display output. 2. You must use a foror while loop to Iterate over the characters in the string. 3. You must format your code using the "Format Document command in your development environment. 4. You must produce output exactly as shown below when the string "Scence is enter. Enter a string: Science Did you enter S-c-i-e-n-c-e? CPTR 141: Objective #5 (1 point) Problem Overview Your task in this homework assignment is to write a program that prompts the user to enter numbers, continuing until the user enters a zero. The program then prinds the sum of a numbers entered Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use input and print to get data from user and display output. 2. You must use a while loop to implement to allow for an unknown number of user entries. 3. You must format your code using the "Format Document command in your development environment. 4. You must produce output exactly as shown below assuming the user enters 2.34", *1.43", "3", 4.30, and . Enter number ('e' to quit): 2.34 Enter a number (* to quit): 1.43 Enter a number ('e' to quit): 3 Enter a number ("e to quit): 4.99 Enter a number ('eto quit): 6 Total Sus: 11.76 Problem Overview Your task in this homework assignment is to write a program that outputs a truncated triangle pattern using the provided starting row length, apex length, and the character to be printed Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use input and print to get data from user and display output. 2. You must use nested loops to print out the figure. 3. You must format your code using the Format Document command in your development environment 4. You must produce output exactly as shown below, assuming the following values are entered. Enter starting/ending row length: 1 Enter apex row length: 4 Enter character to print: TREADME.md Preview README.md CPTR 141: Objective #5 (2 point) Problem Overview Your task in this homework assignment is to write a program that determines If an entered number is prime by checking al poble division of that number. Recall that an integer is prime if it is larger than one and its only divisors are 1 and Itself. Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use input and print to get data from user and display output 2. You must format your code using the "Format Document command in your development environment. 3. You must produce output exactly as shown below, assuming the user enters "88". Y. -13%, and BES Prime Checker Enter a number: 66 66 is not a prime number Would you like to enter another (y)? y Enter a number: 13 13 is a prime number Mould you like to enter another (y)? Goodbye! CPTR 141: Objective #5 (2 point) Problem Overview Your task in this homework assignment is to write a program that prints out the Index, and value of any Moots or boolean values in a provided tuple. Solution Specifications Your solution to this problem munt meet the following criteria. 1. You must use input and print to get data from user and display output. 2. You must use a foror while loop tolerate through the container data.wy_tuple given in the data module. 3. Use the type function on each item in the container, looking for flost or hool types. 4. You must format your code using the "Formal Document command in your development environment. 5. You must produce output exactly as shown below. -- Boolean and Flout Values and Their Indexes -- value at index is True value at Index 6 is 54.23 value at index 9 is 100.99 value at Index 11 is False value at index 12 is True value at Index 13 is False CPTR 141: Objective #5 (4 point) Problem Overview Your task in this homework assignment is to write a program that mimics a movie theater klook. Your program must provide a menu that lets the user perform one d five action 1. List all of the movies available to view 2. Buy tickets for a movie 3. List all of the snacks available for purchase 4. Buy Snacks 5. Exit the system When the user exts the system, they should be presented with a receipt for their total purchase. Make sure you wdude enor checking on all user entstes, prompting the user to rety when an Invalid entry is detected. Solution Specifications Your solution to this problem must meet the following criteria. 1. You must use input and print to get data from user and display output. 2. You must use the dictionary data.movies which contains movie name price keyivalue pairs and the dictionary dute.snucks which contains sack nameprice keyivalue pairs, both from the data module. 3. You must format your code using the "Format Document command in your development environment. 4. You must produce output exactly as shown by the movie_kiosk.pye program. To run this program, right click and choose Run Code. An example is also shown below. TTK V0.1 SERCE Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started