Engineering
Engineering, 17.12.2021 14:00, mak6156

Write a Python program named DataByteConvert that asks the user to enter a Data in MegaBytes (MB) Data is entered only in MegaBytes. The program will then present the
following menu of selections:
1. Convert to Bytes
2. Convert to KiloBytes (KB)
3. Convert to GigaBytes(GB)
4. Convert to TerraBytes(TB)
5. Quit the program
The program will convert the data in MegaBytes(MB) to bytes, kilobytes(KB), GigaBytes(MB),
or TerraBytes(TB), depending on the user's selection rounded to six decimals. Here are the
specific requirements:
• Write a void method named showKiloBytes, which accepts the number of
MegaBytes(MB) as an argument. The method should display the argument
converted to kilobytes(KB). Convert the MB to KB.
• Write a void method named showGigaBytes, which accepts the number of
MegaBytes(MB) as an argument. The method should display the argument
converted to Gigabytes(GB).
• Write a void method named show TerraBytes, which accepts the number of
MegaBytes(MB) as an argument. The method should display the argument
converted to TerraBytes(TB). Convert the MB to TB.
• Write a void method named showBytes, which accepts the number of MegaBytes
(MB) as an argument. The method should display the argument converted to
Bytes(B). Convert the MB to B
• Write a void method named menu that displays the menu of selections. This
method should not accept any arguments.
1. The program should continue to display the menu until the user enters 5 to quit the
program.
2. The program should not accept negative numbers for the data in MegaBytes.
3. If the user selects an invalid choice from the menu, the program should display an error
message.
4. Use Exponential format if needed when converted {:e) formats ...)
5. Use
6. Add comments to show what each function does.

answer
Answers: 1

Other questions on the subject: Engineering

image
Engineering, 04.07.2019 18:10, niicoleassssssf
Aflywheel accelerates for 5 seconds at 2 rad/s2 from a speed of 20 rpm. determine the total number of revolutions of the flywheel during the period of its acceleration. a.5.65 b.8.43 c. 723 d.6.86
Answers: 2
image
Engineering, 04.07.2019 18:20, xcapo1x
Refrigerant-134a enters the compressor of a refrigerator as superheated vapor at 0.14 mpa and -10°c at a rate of 0.05 ka/s and leaves at 0.8 mpa and 50°c. the refrigerant is cooied in the condenser to 0.72 mpa and 26'c. it is then throttled to 0.15 mpa. sketch the t-s diagram for the system and evaluate: 6) the rate of heat removai from the refrigerated space (kw), it) the power input to the compressor (kw), ii) the isentropic efficiency of the compressor (%), and iv) the cop of the refrigerator.
Answers: 2
image
Engineering, 04.07.2019 18:20, AnonymousLizard52303
A2-m rigid tank initially contains saturated water vapor at 100 kpa. the tank is connected to a supply line through a valve. steam is flowing in the supply line at 600 kpa and 300 c. the valve is opened, and steam is allowed to enter the tank until the pressure in the tank reaches the line pressure, at which point the valve is closed. a thermometer placed in the tank indicates that the temperature at the final state is 200°c. determine (a) the mass of steam that has entered the tank (b) the amount of heat transfer.
Answers: 3
image
Engineering, 04.07.2019 19:10, gabigalvis1091
What is the main objective of using reheat rankine cycle?
Answers: 3
Do you know the correct answer?
Write a Python program named DataByteConvert that asks the user to enter a Data in MegaBytes (MB)...

Questions in other subjects:

Konu
Mathematics, 08.07.2019 22:00
Konu
Mathematics, 08.07.2019 22:00
Konu
Mathematics, 08.07.2019 22:00
Konu
Mathematics, 08.07.2019 22:00