Need some help with the coding on For Loops..URGENT
Im a kind of lost with this question and i need some1 to help me go thru the coding..It is not homework i just need to have an full idea on how it is written.Would really appreciate if some1 wrote me the codes along with a simple explanation if possible. I'm having a hard time doing it.. The question is as follows:
A program that uses a for loop to frst take in names and total grades of 5 students.
Your output should look like this:
What is the name of student 1 = ______
Total Mark? ____
The program computes the average of all the total marks and prints out (on screen) the following output.
What is the name of student 1 = Peter
Total Mark? 100
What is the name of student 2 = John
Total Mark? 80
What is the name of student 3 = William
Total Mark? 10
What is the name of student 4 = Kim
Total Mark? 12
What is the name of student 5 = Linda
Total Mark? 0
Peter 100 A
John 90 B
William 10 F
Kim 12 F
Linda 0 F
Average of the class is: 42.4
Thanx, hope its clear enough for u guyz...
Ok. I won't write it for you, but I'll get you started.
1) Do you know what a For/Next loop is? And how you write one?
Then, inside your loop, prompt the user for the students name. Store this in a variable.
And then prompt for the grade. Store that in a variable.
After the loop, print out the results (determine the letter grade as you go), and average out the class grade.
I would recommend using two arrays to store your date. A String array for the names, and an Integer array for the numbers (use Double if you need decimal precision).
The commands to write and read from the console are part of the Console object.
Console.WriteLine and Console.ReadLine should get you started.
help me plz i need a tutorial on the all the looping including the IF condition DO UNTIL and wat not..Wud really appreciate it.I wanna understand it well
Pick up a beginners programming book. Conditional structures are the base for most programming, and any good beginner programming book (regardless of language) will cover them.
If you can find a good beginners programming book for VB.Net, then you won't have to figure out the syntax once you know the concept.
By samtron in forum ASP.NET
Last Post: 02-21-2006, 01:46 AM
By kenn_rosie in forum .NET
Last Post: 01-07-2006, 01:19 PM
By LogicsHere in forum Java
Last Post: 09-23-2005, 11:13 AM
By bhowerton in forum Database
Last Post: 05-24-2005, 07:31 AM
By Jawed in forum VB Classic
Last Post: 04-01-2001, 12:39 PM
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center