Jump to content

Re: Pseudocode Tutorial: The Basics

- - - - -

  • Please log in to reply
2 replies to this topic

#1
hahahehe

hahahehe

    Newbie

  • Members
  • Pip
  • 1 posts
can anyone help me with this????

A text file of hundreds of students' results might include data such as first name, second name, student ID, and number grade. For example five records of such a file might look like this:

10546 Jones Sally 56
09834 Zula Marcos 72
10236 Winston Alexander 81
11643 Granger Thomas 45
10894 Lobos Alexia 75

Develop an algorithm to read such a file of results. It must count the total number of students and count how many students belong to the letter grade groups given in the example below. Ensure your algorithm uses a CASE statement to correctly classify and tally. For example, based on the above excerpt from the file, the output of the algorithm would be:


Total number of students receiving a high distinction (HD): 1
Total number of students receiving a distinction (D): 2
Total number of students receiving a credit ©: 0
Total number of students receiving a pass (P): 1
Total number of students receiving a fail (F): 1
Total number of students: 5

**Hint - HD: 80+, D: 70-79, C: 60-69, P: 50-59, F: <50**

Submit:
a. defining diagram and
b. algorithm for this question.

#2
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
  • Location:Upstate, South Carolina
  • Programming Language:C, C++, PL/SQL, Delphi/Object Pascal, Pascal, Transact-SQL, Others
  • Learning:Java, C#, PHP, JavaScript, Lisp, Fortran, Haskell, Others
What do you have so far? Where are you stuck?
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#3
Vaielab

Vaielab

    Programming God

  • Members
  • PipPipPipPipPipPipPip
  • 547 posts
I'm guessing this is for school...
If you wish to have a good grade, don't forget, some student may have more than 2 name...




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users