Answer:
import java.util.Scanner;
public class CalculatingSales {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int product, quantity;
double total = 0;
while(true) {
System.out.println("Enter product_id and quantity(0 0 to stop): ");
product = sc.nextInt();
quantity = sc.nextInt();
if(product==0 && quantity == 0)
break;
switch (product) {
case 1:
total = total + 2.98*quantity;
break;
case 2:
total = total + 4.50*quantity;
break;
case 3:
total = total + 9.98*quantity;
break;
case 4:
total = total + 4.49*quantity;
break;
case 5:
total = total + 6.87*quantity;
break;
default:
System.out.println("Invalid option");
}
}
System.out.println("total value: "+total);
sc.close();
}
}
Explanation:
- Take the product and quantity as input from user.
- Use a switch statement to multiply the total with their relevant value.
- Display the total value.
The answer Is(C) use shortcut-key combination of ctrl +p to indicate paragraph hope this helped
Giving a child a phone can be very addictive
Answer:
3% inflation rise. No correct cpi option
Explanation:
Consumer Price Index(CPI) is calculated by the Bureau of Economic Analysis and Statistics of a country monthly and annually.
Consumer Price Index(CPI) is used for measuring the changes in the price level of consumer goods and services purchased by households.
Calculating the consumer price index; price in 1964= $1.25, today price= $5.0.
Therefore, consumer price index= Price in today- price in 1964÷ price in 1964,.
Consumer Price index(CPI)= $(5-1.25)/1.25 = 3.75/1.25 = 3 Percent price inflation rise.
For the first cpi; 112-80/80= 0.4 percent( not equal to the 3 Percent inflation rise).
For the second cpi: 141.6-60/60= 1.36 Percent inflation rise(not equal to the 3 Percent inflation rise).
For the third CPI: 126.4-75/75 =0.68 percent inflation rise[not equal to the 3 Percent inflation rise].
For the third CPI: 108.5-90/90=0.21 percent inflation rise(not equal to 3 Percent inflation rise)
Therefore, none of the options are right.
The OC level is primarily used as a regional ISP backbone, and occasionally by very large hospitals, universities, or other major enterprises is <u>OC-48.</u>
<u></u>
<h3>What is the greatest amount of throughput provided by an OC 12?</h3>
OC-12 is a network line with communication speeds of up to 622.08 Mbit/s (payload: 601.344 Mbit/s; overhead: 20.736 Mbit/s). OC-12 lines are generally used by ISPs as wide area network (WAN) connections.
<h3>When using frame relay What is the appellation of the identifier?</h3>
A data-link connection identifier (DLCI) determines the Frame Relay PVC. Frames are routed through one or more virtual circuits determined by DLCIs.
Each DLCI has a permanently configured switching path to a particular destination
To learn more about OC level , refer
brainly.com/question/25899244
#SPJ4
<u></u>