Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I need help completing this assignment before midnight, I am hoping to get help soon CIS 1111 Programming Assignment Description: (20 Points} In this assignment,
I need help completing this assignment before midnight, I am hoping to get help soon
CIS 1111 Programming Assignment Description: (20 Points} In this assignment, you will develop a C++ program which calculates a shipping charge and determines the \"type of trip" for a freight shipping company. The program will prompt the user to enter the distance a package is to be shipped and then display a menu of rates based on package weight. The user, knowing the package weight, will be prompted to choose the appropriate rate from the menu. The program will calculate and display the shipping charge, determine the type of trip from the table below, and display the type of trip. Below is the chart to use to calculate the shipping charges. Freight Shipping Company Rates weight of Package (pounds) Rate per 566 miles shipped 16 pounds or less Dyer 16 pounds but not Over 26 pounds but not Dyer 35 pounds but not NOTICE: we do not ship we do not ship Requirements for your program: $1.13 more than 26 $2.36 more than 35 $3.56 more than 56 $4.96 packages over 56 pounds less than 16 miles or more than 15,666 miles ' The output must be labeled and easyto read. ' 'y'alidate thatthe distance can't be less than 16 miles and more than 15,666 miles. 0 Use a logical operator when 1.ralidatingthe distance to be shipped. Use a logical operator when validating the distance to be shipped. Display a menu of rate choices (similar to the chart above) so the user can choose the appropriate rate based on the package weight. Have the user enter a choice from the menu and use a switch statement to select and assign the rate. Validate that the user selected one of the rates in the menu. Calculate the number of segments (a segment is 500 miles). Round up uneven segments, i.e., segments not evenly divisible by 500, to the next whole number (hint: use modulus or ceil). If the trip is a "long haul" (see table below) there is a "long haul charge" of $1.50 for every segment over 20. The shipping charge is the number of segments times the shipping rate plus any "long haul" charge. Use "if-else" and/or "else-if" and/or "switch" statements to determine the "type of trip" based on the segments and this table: Type of Trip Table: 1 to 13 segments: type of trip is a "short haul" 14 to 20 segments: type of trip is a "medium haul" 21 to 30 segments: type of trip is a "long haul" Provide two screen prints: . the user enters 12,300 miles distance and selects a rate for shipping a 35 pound package. The user enters 1,050 miles distance and selects a rate for shipping a 10 pound package. Display: -the distance entered -the selected rate-the distance entered -the selected rate -the number of segments -the package's shipping charge -the "type of trip" Your program must be documented with the following: // Name // Date // Program Name Submit: Your .cpp file . Screen shot (s) of your outputStep 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