CS135-project1Solved

35.00 $

Category:

Description

5/5 - (1 vote)

 

 

 

Project Goals

 

The goals of this project are to:

  1. Provide you an overview of core c programming concepts
  2. Introduce variables, assignment, choice, and iteration
  3. Explore c arithmetic and logical operators

 

Project Description

 

This project consists of three simple programs:

 

Program 1 (speed conversion):​

 

Write a program that converts measurements from miles per hour to meters per second. This program should:

 

❏ prompt a user to enter a speed in miles per hour, then ❏ output the equivalent speed in meters per second.

 

For example the program should prompt:

 

Please enter a speed in miles per hour:

 

If the user enters 25, then the program should output:

 

25 mph is 11.176 m/s

 

Code for this program should be in a file named ​convert.c

 

Program 2 (compound interest):

 

Write a program that serves as a compound interest rate calculator. This program should:

 

❏ prompt a user to enter a dollar amount (principal) and a percentage (annual interest rate), then

❏ output the value of the principal, plus interest compounded annually each year for 20 years. For example, the program should prompt the user:

 

Please enter the amount of principal and interest percentage:

 

if the user entered: ​1000 5, then the program should output:​

 

  • $1050.00
  • $1102.50
  • $1157.62
  • $1215.51
  • $1276.28
  • $1340.10
  • $1407.10
  • $1477.46
  • $1551.33
  • $1628.89
  • $1710.34
  • $1795.86
  • $1885.65
  • $1979.93
  • $2078.93
  • $2182.87
  • $2292.02
  • $2406.62
  • $2526.95
  • $2653.30

 

Constraints

❏ You must use a while loop ​      to calculate each year’s value.​

 

Code for this program should be in a file named ​interest.c

 

 

Write a program that computes your percentage grade for cs135 given the percentage weight for each portion of this cs135 class in the class syllabus. You must calculate the​              following:

 

❏ project average (must prompt for the number of projects)

❏ quiz average (must prompt for the number of quizzes)

❏ exam average (must prompt for the number of midterms)

❏ overall class average

 

So your program should read each grade (a number between 0.00 and 100.00) for each portion of the class in the following order

 

  1. projects
  2. midterms
  3. quizzes
  4. final project
  5. final exam

 

After reading these values from the terminal, your program should then compute and print the following:

 

  1. The average projects grade (not including the final project)
  2. The average of all the midterm and final grades
  3. The average of the quiz grades
  4. The final percentage grade
  5. Whether these scores qualify a student for cs202 (C (73) or better, as per the syllabus)

 

on the terminal. Here is sample output:

 

Average projects grade: 87.50

Average exam grade: 97.20

Average quiz grade: 92.45

Final grade: 92.45

You can take cs202

 

Constraints

❏ You must use for loops ​         to read in the multiple project, quiz, and midterm grades.​

 

Code for this program should be in a file named ​grade.c

 

Challenge: Deal with the case where you want to know your maximum possible percentage​  grade sometime during the semester and you have not been given all your projects and tests. In this case, reading a -1 for a project or test means that you have yet to receive a grade for this item. You compute the maximum possible percentage by assuming you obtained a 100.00 on this item.

vada, Reno General Catalog.

  • Project1-ho1u3m.zip