Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

The solution on the link below was part 2 the work....please check that out beca

ID: 3758873 • Letter: T

Question

The solution on the link below was part 2 the work....please check that out because my problem requires to modify that solution.

https://www.chegg.com/homework-help/questions-and-answers/need-pseudocode-design-prompt-customer-email-address-titles-three-movies-want-rent-display-q5762739

Question------------Iteration Structure

Modify the pseudocode design that you created in – Part 2 to include statements to prompt the user to enter the movie titles one movie at a time. After the customer has finished entering the movie titles, the system will calculate and print the bill.

Hint: use a loop to process the total bill. (**need to do this using loops like dowhile or repeat)

     Add the statement(s) for the following: If customer rents 3 movies, they receive 1 of the three movies for free.

Explanation / Answer

Below is the PseudoCode you have requested

Print_Bill
Step 1   Set error_message to blank
Step 2   Tax_rate = .05
Step 3   Movie_cost=0 and movie_no=0
Step 4   Prompt the operator for email, num_movies
Step 5   Get email, num_movie
Step 6   IF (num_movies<1 OR num_movies>3) THEN
       error_message = ‘Invalid Quantity '
       Print num_movie, error_message
       ELSE
       Do                                                           //Do While loop to enter three movies
           movie_no ++
           Prompt for Movie_title for movie_no
           If(movie_rating=R)then
               Prompt for age
               IF age < 17 THEN
               error_message = ‘Must be 17 or older to Rent'
               Print email, movie_title1, error_message
               Valid_age = false
               num_movies = num_movies - 1
               ENDIF
           ENDIF
           Movie_cost =Movie_cost+$1.5
           if(Movie_no=3 and Num_movie=3)then //Checking for loop End to Finalize the Bill
                   Print 'One movie is free For You'
                   total_bill=Movie_cost+ Movie_cost * tax_rate
                   total_bill=movie_cost-1.5                       //$1.5 will get minus from total_bill as one movie is free
                   Print Email, Bill
           else if (Movie_no=3) then                               //If Movie_no is not equals to 3 this means no Discount
                   total_bill=Movie_cost+ Movie_cost * tax_rate
                   Print Email, Bill
           ENDIF          
       While(movie_no<=3)
       ENDIF
       END