RU beehive logo ITEC dept promo banner
ITEC 120
2008fall
aaray,
ejderrick,
ibarland,
jmdymacek

homeinfolabshwsexams
textbookjava.lang docsjava.util docsarchive

lect10a
Lists

class Quiz {
  java.util.Scanner s = new java.util.Scanner(System.in);


  /* Find the largest grade entered.
   * We assume the input is only positive integers (and there's at least one).
   * @return the largest number read by s.
   */
  int maxScore_v1() {
    // Use a while loop.




    }


  static final int NUM_SCORES = 1000;  // Abbreviate: "NS"

  /* Find the largest score of the next 1000 (NUM_SCORES) in the input.
   * We assume the input is only positive integers (and there's at least 1000).
   * @return the largest number read by s, in the next {@value NUM_SCORES}.
   */
  int maxScore_v2() {
    // Use a while loop.




    }


  /* Find the largest number of the next 1000 in the input.
   * We assume the input is only positive integers (and there's at least 1000).
   * @return the largest number read by s, in the next 1000.
   */
  int maxScore_v3() {
    // Use a for-loop.




    }

  }

Wrapper classes

Double, Boolean, Integer (not “Int”), Character (not “Char”), plus seldom-used Long, Short, Byte, Float.

homeinfolabshwsexams
textbookjava.lang docsjava.util docsarchive


©2008, Ian Barland, Radford University
Last modified 2008.Nov.10 (Mon)
Please mail any suggestions
(incl. typos, broken links)
to iba�rlandrad�ford.edu
Powered by PLT Scheme