This is a simple Java program, so you will need to download jdk (any version 1.3.1 or higher should work fine) from
Sun's website. I assume that if you are running Linux or Mac, you will know
what to do with the .class and/or the .java files. The program is fairly self explanatory.
However, if you need any more help, or if you are using Windows and aren't sure what you need to do, here are some
I'm guessing that you probably are only interested in the program itself, and not the actual source code, so you only want to deal with the first link above. Right click on it and select "Save Target As..." and save the file to the "bin" folder in the "jdk" folder (what you downloaded off Sun's website).
Open up a command prompt, and navigate to the "bin" folder using the "cd" (change directory) command. For instance, if the command prompt line said "C:\" and I had the jdk1.3.1 folder in the C:\ directory, I would type "cd jdk1.3.1\bin".
Once you have navigated to the proper directory, type "java Sequence". This will run the program. Anytime you want to rerun the program, just type this phrase in again (in certain versions of windows, you can press the up arrow key to reach previous commands so you don't have to type them in again). If you ever wish to cancel the program while it's running, just press CTRL-C.
The program asks you to enter a value for p (a prime greater than 2), and then a value for q (a different prime greater than 2). The program then will calculate the values, and generate a file named "Sequence p q.txt" in your "bin" directory. The file lists the values of p and q, and then the values that are gaps, along with the lengths of the contiguous gaps. For instance, the output line "[235, 237] 3" means that there is a gap consisting of the numbers 235, 236, and 237, and this gap has length 3.