Examlex

Solved

Write a Multiple-Alternative Selection Structure That Determines the Shipping Charge

question 31

Essay

Write a multiple-alternative selection structure that determines the shipping charge based on the total order amount entered by the user.The shipping charge is stored in the intShipCharge variable.The total order amount is stored in the decTotalOrder variable.The shipping charge is $9 for all orders under $25.The shipping charge is $8 for all orders of $25 to $50.The shipping charge is $7 for all orders where the total order amount is greater than $50.If the user does not enter a valid total order amount (less than 0),display "Please enter a valid amount." in the lblMessage control.Use the Select Case statement.


Definitions:

Dimethylpropane

A branched alkane with the formula C5H12, also known as isopentane, a component of some fuels.

Methyloctane

A type of hydrocarbon compound characterized by its chemical structure that includes an octane backbone with a methyl group attached.

Condensed Structural Formula

A condensed structural formula is a method of describing the elements or molecules that compose a compound and their arrangement in a compact form without drawing full structural diagrams.

Dimethylbutane

An organic compound with the formula C6H14, a type of alkane that is used as a fuel.

Related Questions