Question
(Hard drive storage capacity) If you buy a 40GB hard drive, then chances are that the actual storage on the hard drive is not 40GB.
(Hard drive storage capacity) If you buy a 40GB hard drive, then chances are that the actual storage on the hard drive is not 40GB. This is due to the fact that, typically, a manufacturer uses 1000 bytes as the value of 1K bytes, 1000K bytes as the value of 1MB, 1000MB as the value of 1GB. Therefore, a 40GB byte hard drive contains 40,000,000,000 bytes. However, in computer memory, as given in Table 1-1 (Chapter 1), 1KB is equal to 1024 bytes, and so on. So the actual storage on a 40GB hard drive is approximately 37.25GB. (You might like to read the fine print next time you buy a hard drive.) Write a program that prompts the user to enter the size of the hard drive specified by the manufacturer, on the hard drive box, and outputs the actual storage capacity of the hard drive.
Step 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