All pastes #289147 Raw Edit

Mine

public java v1 · immutable
#289147 ·published 2006-12-22 22:14 UTC
rendered paste body
public class Battleship {    public static void main(String[] args){    if (args.length != 2){        System.err.println("Usage: java Battleship N config-file");        System.exit(0);        }    int testint;    try {        testint = Integer.parseInt(args[0]);        } catch (NumberFormatException nfe) {            System.err.println("Usage: java Battleship N config-file");        }    try {        testint = Integer.parseInt(args[0]);        if(testint < 5);        } catch (NumberFormatException nfe) {            System.err.println("Board must be at least 5 by 5.");        }    try {        testint = Integer.parseInt(args[0]);        if(testint > 26);        } catch (NumberFormatException nfe) {            System.err.println("Board must be at most 26 by 26.");        }    }}