Homework 2
Video Game Database
Description:

Write a program in which the user can:

  1. Read a videogame collection file. The file is assumed to have the name & console and is tab delimited.
  2. Search the contents of the file from part 1. The user enters the name of the game, then the name of the console.
  3. Print out the current search results to the console.
  4. Print out the current search results to a new file with the option to append to said file. The user must specify the name of the file and whether or not to append.
  5. Keeps running until the user quits.
Suggested Methodology:

You can solve this in a number of way; here's a way you make take to approach this problem.

Example Dialog
      
        Enter 1 to load the videogame database
        Enter 2 to search the database
        Enter 3 to print current results
        Enter 4 to print current results to file
        Enter 0 to quit
        1
        Enter the file name: Collection.txt
        Enter 1 to load the videogame database
        Enter 2 to search the database
        Enter 3 to print current results
        Enter 4 to print current results to file
        Enter 0 to quit
        2
        Enter the name of the game or '*' for all names: super
        Enter the name of the console or '*' for all consoles: nintendo
        Enter 1 to load the videogame database
        Enter 2 to search the database
        Enter 3 to print current results
        Enter 4 to print current results to file
        Enter 0 to quit
        3
        Super Alfred Chicken    Super Nintendo [NA]
        "Super Aquatic Games Starring the Aquabats, The"        Super Nintendo [NA]
        Super Castlevania IV    Super Nintendo [NA]
        Super Dodge Ball        Nintendo Entertainment System [US]
        Super Empire Strikes Back       Super Nintendo [NA]
        Super Ghouls 'N Ghosts  Super Nintendo [NA]
        Super Glove Ball        Nintendo Entertainment System [US]
        Super Mario All-Stars   Super Nintendo [NA]
        Super Mario Bros.  (5 Screw Cartridge)  Nintendo Entertainment System [US]
        Super Mario Bros. / Duck Hunt (No Nintendo Seal of Quality)     Nintendo Entertainment System [US]
        Super Mario Bros. 2 (No Nintendo Seal of Quality)       Nintendo Entertainment System [US]
        Super Mario Bros. 3 (Bros. above Mario's Head)  Nintendo Entertainment System [US]
        Super Mario Kart        Super Nintendo [NA]
        Super Mario World       Super Nintendo [NA]
        Super Mario World 2: Yoshi's Island     Super Nintendo [NA]
        Super Metroid   Super Nintendo [NA]
        Super Noah's Ark 3D     Super Nintendo [NA]
        Super Pitfall (3 Screw Cartridge)       Nintendo Entertainment System [US]
        Super Punch-Out!!       Super Nintendo [NA]
        Super Scope 6   Super Nintendo [NA]
        Super Spike V'Ball / Nintendo World Cup Nintendo Entertainment System [US]
        Super Star Wars (JVC)   Super Nintendo [NA]
        Super Star Wars: Return of the Jedi (JVC)       Super Nintendo [EU]
        Super Street Fighter II Super Nintendo [NA]
        Super Team Games        Nintendo Entertainment System [US]
        Super Tennis    Super Nintendo [NA]
        Enter 1 to load the videogame database
        Enter 2 to search the database
        Enter 3 to print current results
        Enter 4 to print current results to file
        Enter 0 to quit
        4
        Enter the file name to print out: superGames.txt
        Append to file (true/false): false
        Enter 1 to load the videogame database
        Enter 2 to search the database
        Enter 3 to print current results
        Enter 4 to print current results to file
        Enter 0 to quit
        0
        Goodbye
      
    
Finally

Submit the files to the dropbox