Calculate the magnification of a microscope.
It's not clear who invented the first microscope, but the Dutch spectacle maker Zacharias Janssen (b. 1585) is credited with making one of the earliest compound microscopes (ones that used two lenses) around 1600. Today's electron microscopes allow us to see individual atoms.
Write a program that calculates the magnification of an image from the actual size of a specimen in micrometers, and the output image size in centimeters.
Use this boilerplate code as a starting point:
Remember to add a comment before a subprogram or selection statement to explain its purpose.
Enter the actual size in micrometers: 80
Enter the image size in centimeters: 10
The magnification is 1250.0 X
Use these resources as a reference to help you meet the success criteria.
Run the unit tests below to check that your program has met the success criteria.
Enter the actual size in micrometers: 80
Enter the image size in centimeters: 4
The total magnification is 500.0 X
Enter the actual size in micrometers: 30
Enter the image size in centimeters: 3
The magnification is 1000.0 X
Check that you have used comments within the code to describe the purpose of subprograms.