Example program solving BIO'99 Round One Question 2
|
To see this solution, you need a browser that is able to run
Java applets. Alternatively,
follow the instructions at the end of this page for how to run
the program outside your browser.
To run the program:
- Click on the 'Start BIO99R1Q2App' button. The program is now running.
- Click inside the text window to activate keyboard input to the program.
- Type in your input as required by the program.
- To re-run the program click on the button to 'Stop' the
program, then click 'Start' again.
The program first asks you to type in the (x y) co-ordinates of five atoms
(x and y between 2 and 9). It then displays the arrangement of the
atoms in the box. You can then type in instructions on where rays are
to be fired from: a letter (T, B, L or R) then a number (1 to 10). For example
T 6 fires the ray from the top along column 6.
BIO'99 Round One
BIO'2000 Sample paper
|
Running the program with Java outside a browser
If you have a Java runtime interpreter installed on your computer,
you can run the program without using a browser. You need to
download the files
BIO99R1Q2App.class
and
AppletConsoleApp.class
to your computer.
In the directory containing these files, execute the application
BIO99R1Q2App.class
with the command
java BIO99R1Q2App.class
substituting the name of your Java runtime interpreter for
java
. Alternatively, follow the instructions
given in your Java documentation.
Obtaining a Java runtime interpreter
Free Java runtime interpreters are available for most major computer
systems. See Sun's Java website
for details (look for 'Java Runtime Environment').
Solution copyright (c) 1999 The British Informatics Olympiad (BIO).
This program may be freely copied by persons or organisations
involved in the British Informatics Olympiad or the International
Olympiad in Informatics, on condition that no changes are made and
this notice is not altered. Distribution for profit is forbidden
unless permission is first obtained in writing from the BIO.
This program is for educational purposes only and comes with no
warranty, implied or otherwise, as to its fitness for any purpose.
Author: Antony Rix
Internet: http://www.christs.cam.ac.uk/bio/
E-mail: (see contact details from home page)
S-mail:
The British Informatics Olympiad
Christ's College
Cambridge CB2 3BU
United Kingdom
The British Informatics Olympiad