A Game maintains scores for its players in a comma delimited sequential file “scores.txt” with the record structure outlined below.
scores.txt record structure
Field Name Type
Player Number String
A program is required that will allow them enter a player number, the program will then search the file, and display the players name, and the score for chosen player. If the player is not found display a message stating “No match found”. Alongside the score, you must display the citation, use the table below do to determine the citation.
Less than 400 Sluggish Snail
between 400 and 599 Ambling Armadeillo
Between 600 and 699 Bobbing Bobcat
Between 700 and 999 Rocketing Rabbit
Greater than 999 TurboCharged Cheetah
Enter Player Number: G002
Player name : Loose Cannon
Score : 750
You are a Rocketing rabbit
Search Again (y/n) :
My Attempt so far:
Am i on the right track??Code:string scores = new string streamreader myfile = file.opentext("scores.txt"); string lineIn; lineIn = myfile.Readline(); Console.Write("Enter name : "); string target = Console.ReadLine();
Anyone any ideas??