public static double getDouble(String prompt, double low, double high) {
		final int ALLOWABLE_INPUT_FAILURES = 3; // Avoid leaving a user stuck in here infinitely. If they fail to enter an int after 3 tries, bail out anyway.
		String response;
		int inputFailureCount = 0;
		while (true) { // use an infinite loop. Exit will occur on return if they enter a valid <i>int</i> or after exhausting the attempt limit.
			// try-block used to manage an interaction where there may be a failure: in particular, a user might enter something other than a parseable <i>int</i> value
			try {
				response = JOptionPane.showInputDialog(prompt); // no possible failure here, since we can pick up any pattern of characters
				// Possible failure on following line, since non-<i>double</i> characters will generate an exception in the <i>Double.parseDouble()</i> method
				// If a failure occurs in the <i>Double.parseDouble()</i> method call, then program execution will <i>throw</i> an exception that will immediately 
				//   abandon the <i>try</i>-block and jump to the closest matching <i>catch</i>-block. 
				double convertedResponse = Double.parseDouble(response);
				// we can only arrive here if the <i>Integer.parseInt()</i> method returned normally, that is, it did not <i>throw</i> an exception.
				if (convertedResponse < low || convertedResponse > high) {
					if (++inputFailureCount > ALLOWABLE_INPUT_FAILURES) {
						showErrorGUI("Too many unsuccessful attempts. Setting to 0");
						return 0.0;	// exits on failure to complete input operation
					}
					showErrorGUI("Number must be between " + low + " and " + high + " (inclusive).");
				} else
					return convertedResponse; // exits on successful completion of input operation
			} catch (NumberFormatException | NullPointerException exception) { // only arrive here if there was a failure in the <i>Double.parseInt()</i> method or <Esc> at dialog
				if (++inputFailureCount < ALLOWABLE_INPUT_FAILURES) {
					showErrorGUI("You must enter an integer.");
				} else {
					showErrorGUI("Too many unsuccessful attempts. Setting to 0");
					return 0.0;	// exits on failure to complete input operation
				}
			}
		}
	} // end public static double getDouble()