Problem Solving and Computer Programming

To become more familiar with:

- Problem solving concepts
- Simple Algorithm Development
- Writing and compiling simple C programs

Problems 1-3 are problem solving and algorithm problems. For each of these three problems, complete two parts:

- solve the problem as stated, and
- give a generic algorithm for solving the problem.

- (5 points) Determine the dollar value of a coin collection that contains 13 pennies, 2 nickels, 4 dimes, 7 quarters, and 5 silver dollars.
- Allow the user to input the numbers of the different coins.
- The algorithm should output the total value of the coin collection.
- (5 points) You have been saving dimes and nickels in your piggy bank (everything counts). After counting 150 total coins, you know that you have $9.45. How many of each coin do you have?
- Allow the user to input the total number of coins and the total dollar amount.
- The output should be the number of dimes and the number of nickels.
- (5 points) Bob loans Bill $0.01 (one penny) under the condition that for every day that Bill does not pay Bob back, the amount that Bill owes Bob doubles (x2). If Bill does not pay Bob back, how many days go by before Bill owes Bob over $1,000,000.00?
- The user should be allowed to specify the initial loan amount, the rate of increase (interest rate), and the total payback amount to be exceeded.
- The output is the number of days that it takes the payback amount to grow larger that the desired total payback amount.
- You don't need complex algebra to solve any of these problems!
- Review the Algorithms II slides, particularly slides 20-25.
- Try to think like a computer!
- (10 points) Write a C program, called
, that prompts the user to input three initials, scans the three initials, and then outputs "Hello, XYZ!", where X,Y, and Z are the three input initials, respectively. Your program should be well formatted and documented with the necessary information to identify it as yours in the header comment. See the C Coding Standards for more details.*campusid*_hello.c

**Hints:**- You only need a total of one
`scanf`and two`printf`calls! - You can print/scan the value of more than one variable in a single
`printf`/`scanf`call. - Check the third slide of the Algorithms II lecture for more help with
`scanf`and`printf`. The textbook is also helpful. **DO NOT**cut and paste from Microsoft Word or other text editors into your terminal window! They use non-standard characters that confuse gcc. I will explain more in class.

Compilewith the "gcc" compiler. Execute your program to verify that it works correctly.*campusid*_hello.c - You only need a total of one

When you have finished, submit your

Additionally, email your