C++ Homework #1

Please support our C++ advertiser: Intel Parallel Studio Home
Closed Thread

Join Date: Jan 2008
Posts: 6
Reputation: vze2zv5v is an unknown quantity at this point 
Solved Threads: 0
vze2zv5v vze2zv5v is offline Offline
Newbie Poster

C++ Homework #1

 
0
  #1
Jan 30th, 2008
This is Paul Michael. I need help with my homework. The sooner you can help me the better. I am stuck. Please give me the solution ASAP.
Attached Files
File Type: doc cs5403HW1.doc (42.0 KB, 9 views)
Quick reply to this message  
Join Date: Dec 2007
Posts: 449
Reputation: Agni is a jewel in the rough Agni is a jewel in the rough Agni is a jewel in the rough 
Solved Threads: 70
Sponsor
Agni's Avatar
Agni Agni is offline Offline
Posting Pro in Training

Re: C++ Homework #1

 
0
  #2
Jan 30th, 2008
At what point are you stuck?
Quick reply to this message  
Join Date: Jan 2008
Posts: 6
Reputation: vze2zv5v is an unknown quantity at this point 
Solved Threads: 0
vze2zv5v vze2zv5v is offline Offline
Newbie Poster

Re: C++ Homework #1

 
0
  #3
Jan 30th, 2008
CS540 Homework #1 Spring 2008
Due Monday 2/4/08 at midnight

This assignment is a review of CS530 material. It is probably the most difficult program this semester!
Be sure to include the following information in comment statements at the beginning of your program: Your name, Homework # 1 and a brief description of the assignment.

ALSO PLEASE INCLUDE THE return 0; statement in main.

The grade you receive will be based on 4 components:
(1) it compiled
(2) it ran
( 3) it gave correct output
(4) programming style (clarity, organization, use of functions, documentation).
Grades will range from 0 - 10.
No extensions on the programs unless I agree to it; Each program is to be handed in electronically by midnight on the due date.

Write your code in a file called hw1.cpp and submit it electronically using the dropbox for the assignment on the eCollege website.

The following information has been recorded for each of the students in a certain computer science course:
student name in the form LAST,FIRST at most 20 characters long (no embedded blanks)
score on Midterm ( an integer in the range 0 100)
score on Final Exam (an integer in the range 0 100)
12 homework/quiz grades (each an integer in the range 0 10)

We wish to store all the pertinent information for an individual student in a struct, called A_STUDENT.
In particular, one part of the struct should be an array to hold the particular student's 12 homework/quiz grades.

We wish to store the information for all the students in the entire class as a single array of structs, called THE_CLASS; You may assume that there are at most 10 students in the class, but you don’t know how many there are beforehand and may not ask.

Write and run a C++ program using the compiler of your choice, that will print out the following information in a single table* with an appropriate header line to the screen: the student’s name, his score on the Midterm, his overall homework_quiz grade, his score on the final exam, his course average (carried out to 2 decimal places), and his letter grade for the course, WHERE
1. the homework quiz grade is obtained by passing a function HQGRADE a particular student's array of 12 homework quiz grades and having the function return the sum of the best ten grades (this will be an integer in 0 100) .
2. student's average = .30(Midterm + Final) + .40(HQGRADE)
3. course grades are determined as follows:
average grade for course
90 – 100 A
80 <<90 B
70 <<80 C
below 70 F where << means less than, but not equal to

*Have the students displayed in the table in decreasing order of their final average.

INPUT: Call the input file data1.txt. I’ve included some sample input below, BUT your code should run for ANY input file! Please include the code for inputting the file in your program……DO NOT INPUT THE DATA VIA THE COMMAND LINE.

Sample input format: (note the word name , etc is NOT in the input file)
name Doe,John
midterm. Final 78 82
12 homework quiz grades 4 5 8 9 10 10 8 7 4 8 9 10

SAMPLE INPUT:
Smith,Tom
90 100
10 10 10 10 10 10 2 1 10 10 10 10
Jones,Mary
90 90
1 2 3 4 5 6 7 8 9 10 10 10
Grieco,Linda
100 100
10 10 10 10 10 10 10 10 10 10 10 10
Ball,Lucille
50 90
10 10 2 7 10 1 1 10 10 10 10 10

OUTPUT: Have your program print the output table to the screen

SAMPLE OUTPUT:
Name Midterm HQAvg Final Avg Grade

Grieco,Linda 100 100 100 100 A

Smith,Tom 90 100 100 97 A

Jones,Mary 90 72 90 82.8 B

Ball,Lucille 50 89 90 77.59 C
Quick reply to this message  
Join Date: Jan 2008
Posts: 6
Reputation: vze2zv5v is an unknown quantity at this point 
Solved Threads: 0
vze2zv5v vze2zv5v is offline Offline
Newbie Poster

Re: C++ Homework #1

 
0
  #4
Jan 30th, 2008
I cannot do it at all. Can you give me the complete solution to the problem? Please reply.
Quick reply to this message  
Join Date: Jul 2006
Posts: 647
Reputation: jaepi is an unknown quantity at this point 
Solved Threads: 4
jaepi's Avatar
jaepi jaepi is offline Offline
Practically a Master Poster

Re: C++ Homework #1

 
0
  #5
Jan 30th, 2008
Hahahaha... You're a funny man...
Retreat!!!
Quick reply to this message  
Join Date: Dec 2007
Posts: 449
Reputation: Agni is a jewel in the rough Agni is a jewel in the rough Agni is a jewel in the rough 
Solved Threads: 70
Sponsor
Agni's Avatar
Agni Agni is offline Offline
Posting Pro in Training

Re: C++ Homework #1

 
0
  #6
Jan 30th, 2008
how much can you pay ??
Quick reply to this message  
Join Date: Jan 2008
Posts: 6
Reputation: vze2zv5v is an unknown quantity at this point 
Solved Threads: 0
vze2zv5v vze2zv5v is offline Offline
Newbie Poster

Re: C++ Homework #1

 
0
  #7
Jan 30th, 2008
I can pay with Paypal via a credit card.
Quick reply to this message  
Join Date: Jan 2008
Posts: 6
Reputation: vze2zv5v is an unknown quantity at this point 
Solved Threads: 0
vze2zv5v vze2zv5v is offline Offline
Newbie Poster

Re: C++ Homework #1

 
0
  #8
Jan 30th, 2008
I can pay you 20 dollars.
Quick reply to this message  
Join Date: Jul 2006
Posts: 647
Reputation: jaepi is an unknown quantity at this point 
Solved Threads: 4
jaepi's Avatar
jaepi jaepi is offline Offline
Practically a Master Poster

Re: C++ Homework #1

 
0
  #9
Jan 30th, 2008
Hahahahaha....That's really really funny...
Retreat!!!
Quick reply to this message  
Join Date: Dec 2005
Posts: 5,850
Reputation: Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute 
Solved Threads: 749
Team Colleague
Salem's Avatar
Salem Salem is offline Offline
Void main'ers are DOOMed

Re: C++ Homework #1

 
0
  #10
Jan 30th, 2008
Quick reply to this message  
Closed Thread

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC