// TS8802 Project by John Phillips on 6/24/2003 last revised 6/26/2003

// This class just demonstates that other types of problems can be used
// by the quiz program. I would like for it to eventually be a file-based
// or database-based solution with a large set of questions to draw on.

public class Terms extends Problem {
  
  public Terms()
  {
    newProblem();
  }

  public void newProblem()
  {
    int decNum = ( int ) ( Math.random() * 3 );
    switch( decNum ) {
      case 0:
        setAnswer( "8" );
        setQuestion( "How many bits are in a byte?" );
        break;
      case 1:
        setAnswer( "B" );
        setQuestion( "Select the letter of the best choice.\n\n" + 
          "The brains of the computer:\nA. RAM  B. CPU  C. POW  D. GHZ" );
        break;
      case 2:
        setAnswer( "A" );
        setQuestion( "Select the letter of the best choice.\n\n" + 
          "Volatile read/write memory:\nA. RAM  B. CPU  C. POW  D. GHZ" );
        break;     
    }
  }
}