1) Explain what is happening when the program is compiling and linking does and why this process is necessary.
2) What is special about the main function?
3) The instruction “#include<iostream>” is generally present at the top each program. What does this instruction do?
4) Convert the following binary numbers to decimals number. Show your work.
a) 1011 b) 10101 c)111 d)1100001
5) Convert the following decimal numbers to binary. Show your work.
a)12 b)43 c)8 d)20
6) (Upload as Source) Write a program which calculates and prints the interest earned on a savings account over a single year. Implement this by declaring a principle variable of type double and initialize the variable to one thousand two hundred and on dollar and forty cents. Initialize another double variable representing the interest rate, and set the value to 18%. Finally calculate the interest earned and print the result to console.
7) (Upload as Source) Using a similar procedure as the previous problem, write a program which converts 36.3 degrees Fahrenheit to Celsius using the equation listed below. Instead of integers, use doubles to store the Fahrenheit and Celsius values.
This material may consist of step-by-step explanations on how to solve a problem or examples of proper writing, including the use of citations, references, bibliographies, and formatting. This material is made available for the sole purpose of studying and learning - misuse is strictly forbidden.
1. Explain what is happening when the program is compiling and linking does and why this process is necessary.
Answer: Compilation and linking are both steps of the creating executable file process. The source code (in this case the .cpp file) is processed during compilation phase and it is created an object file. Practically the compiler outputs a series of machine language instructions corresponding to the initial source code file. During compilation phase it is possible to be created many such object files. In order to run the program, these object files must be linked. This is performed during linking phase. Only if the linking phase is successfully the program can run....
This is only a preview of the solution. Please use the purchase button to see the entire solution