logo Use CA10RAM to get 10%* Discount.
Order Nowlogo
(5/5)

Write a program whose main function is merely a collection of variables and function calls.

INSTRUCTIONS TO CANDIDATES
ANSWER ALL QUESTIONS

Write a program whose main function is merely a collection of variables and function calls. The main function/program reads students name, followed by their test scores. The program should output each student name followed by the test score and relevant grade (Pass (P) or Fail(F), A). It should also print the names and test scores of the student with a test score higher than the average test score.

 

The student data should be stored in a struct variable of type studentType, which has two components: studentLName of type string and testScore of type integer (testScore is between 0 and 100), and grade of type char. (10 points)

Suppose the class has 3 students. Use an array of 3 components of type studentType. (5 points)

Your program must contain the following functions:

  1. A function to find the average test score – the function accepts a structure of studentType and the number of students as a parameter. Example. getAverage(Students myStu[], int noOfStudent)

(30 points);

 

  1. A function to print the student name, test score and a letter grade of all the students having a test score greater than or equal to the average test score. Example:  printAverage(Students myStu[], int no of student, float aveScore);

The letter grade in the printAverage function has the following values:

  1. P - if the test score is greater than the average and less than 90.
  2. A – if the test score is greater than 90

(30 points)

 

  1. The main function reads the student information from the user and populate the student structure. The main function should also print the average test scores for all the students. (20 points)
  2. The main program should be able to execute until the user enters a Y to exit the program (5 points).
(5/5)
Attachments:

Related Questions

. Introgramming & Unix Fall 2018, CRN 44882, Oakland University Homework Assignment 6 - Using Arrays and Functions in C

DescriptionIn this final assignment, the students will demonstrate their ability to apply two ma

. The standard path finding involves finding the (shortest) path from an origin to a destination, typically on a map. This is an

Path finding involves finding a path from A to B. Typically we want the path to have certain properties,such as being the shortest or to avoid going t

. Develop a program to emulate a purchase transaction at a retail store. This program will have two classes, a LineItem class and a Transaction class. The LineItem class will represent an individual

Develop a program to emulate a purchase transaction at a retail store. Thisprogram will have two classes, a LineItem class and a Transaction class. Th

. SeaPort Project series For this set of projects for the course, we wish to simulate some of the aspects of a number of Sea Ports. Here are the classes and their instance variables we wish to define:

1 Project 1 Introduction - the SeaPort Project series For this set of projects for the course, we wish to simulate some of the aspects of a number of

. Project 2 Introduction - the SeaPort Project series For this set of projects for the course, we wish to simulate some of the aspects of a number of Sea Ports. Here are the classes and their instance variables we wish to define:

1 Project 2 Introduction - the SeaPort Project series For this set of projects for the course, we wish to simulate some of the aspects of a number of

Ask This Question To Be Solved By Our ExpertsGet A+ Grade Solution Guaranteed

expert
Um e HaniScience

691 Answers

Hire Me
expert
Muhammad Ali HaiderFinance

786 Answers

Hire Me
expert
Husnain SaeedComputer science

972 Answers

Hire Me
expert
Atharva PatilComputer science

520 Answers

Hire Me

Get Free Quote!

333 Experts Online