Reversi V2.4

Home Description

This is Version V2.4 of my Reversi applet. It once (in Nov. '96) had an IOS rating: 1408 on level "Amateur"! Not bad for a Java applet, eh?

Have fun! (Be patient - it takes a while to load the applet.)

You want to play an interesting game? Choose level "Amateur" and no timeout. See if you can beat the applet!

It looks like the browser you're using doesn't support Java. Some explanations:
  • Black starts (that's you unless you clicked on "Computer starts": then the computer plays black and you'll play white).
  • A little red dot indicates your legal moves. If "Show possible moves" is checked, all your possible moves are show in a lighter shade of green.
  • The computer's last move is marked by a small cross.
  • If the computer detects that you have to pass, it'll immediately make another move, until you can move again.
  • The higher you set the level, the better the applet will play - but it'll also take longer to compute its next move.
  • You can set the maximum time the applet takes for a move. Very useful on the higher levels! (If "Time" is visible, there's no limit.)
  • If you don't know Reversi - the rules are below.

If this applet doesn't work for you for some reason, let me know! (But check out the (small) list of known problems first.)
A note for users of Opera 4.02.

I don't even remember how this started - but one fine day I rewarded myself for just having finished and sent off a paper by cruising the web in search of interactive Reversi (also called Othello) games. I found a couple of Java implementations, but all of them were disappointingly easy to beat - and I'm far from being a good Reversi player!

Or maybe it didn't start with this but with a rather strong Reversi program I wrote in C back in 1993. While it only had a simple character interface, it used state-of-the-art techniques for the game engine. It played quite well: on the "Amateur" level, it beat me regularly - and I'm far from being the world's worst Reversi player!

Wherever this started, I decided to put my Reversi program on the web. I just had to learn Java and re-implement my old C program. To get a feeling for Java, I shamelessly copied Ben Fry's Java implementation of Reversi. Then I ported my old game engine to Java, rewriting the applet completely in the process.

The above Reversi game applet is not vary fast - after all, Java applets are interpreted, so you cannot expect the same speed as in a compiled C program. Levels "Easy" and "Beginner" (1- and 2-move look-ahead) give adequate response times, but also are not too hard to beat. Level "Amateur" (4-move look-ahead) can take some time, but it's still tolerable. It's already rather difficult to beat. Level "Expert" (6-move look-ahead) may take a couple of minutes to compute its next move.

The "Time" setting usually has no effect on the "Easy" level: on that level, the applet will find a move in less than 30 seconds anyway. On all other levels, the applet plays best when there's no time limit. The more time you give it for thinking, the better it'll play!

If you want to know more about the internals of this applet, read a description of the algorithms used.

Note: the applet uses auxiliary game information stored in a table. If this table cannot be loaded, you still can play, but the applet will not play very well. It should pop up a window with a warning message in this case.

Disappointed by my applet's play? Sorry, but with a 4-ply (level "Amateur") or 6-ply (level "Expert") look-ahead I can't do much better. But you can find much stronger opponents (humans and programs) on IOS, the Internet Othello Server. (If you've never before played on IOS, read the guide to IOS first! - But note that the host given there is wrong: IOS recently moved and is now at, port 5000!)

My applet also played a couple of games on IOS (under the name "wolfj"). Its consolidated rating on IOS on Nov 15, 1996 was 1408 on level "Amateur". This is probably a little too high, its true rating is more likely to be somewhere between 1300 and 1350.

The Rules

Reversi is a two-player game. One player has the black stones (you), the other the white ones (the computer). The players alternatingly set stones on the board, black starts. Any stones of the opponent that get caught between two of your stones by a newly set stone are flipped, i.e., they change color. You may only set a piece if doing so will flip at least one other piece. Otherwise, you have to pass, and it's again your opponent's turn. The game ends when either the board is full, or neither player can make a move. At that moment, the player who has the most pieces of his color has won. Draws are possible.

More information about the game of Reversi (or Othello) can be found in the guide published by the International Internet Othello Association.

A very good introduction to the game of Othello can be found on Colin Springer's Othello Pages.

FAQ List

Well, "FAQ List" is a big word, but there are a few questions posed regularly:

Can I download the applet's code to play offline?
Well, I never tried it, but I don't see a reason why you couldn't. You'll need to grab the files Othello.jar and table.code.gz. See the license for information on how to get the applet and on what you are allowed to do and what not.

Could you please send me the source code of your old C program for Reversi/Othello
No, I can't. First, it's been quite a while, and I'm not even sure if I still have that C code at all; second, the code is pretty ugly; and third, it contains some bugs.

Could you please send me the Java source code for the applet?
No, I won't.

I am implementing my own Reversi/Othello program. Can you help me?
I just might, if you ask clever questions that show that you have given this some thought of your own, if I happen to have the time, and if you read my technical pages on the applet first. Chances are that those, or the references given there, will already answer your implementation questions.

Known Problems

Despite my best efforts to implement this applet properly, there are some minor problems I could not resolve:

Opera 4.02

I have not succeeded to make Opera 4.02 with Sun's JRE 1.3 successfully run the applet. Since it runs well on Netscape 4.7, Internet Explorer 4.0, and Sun's appletviewer from JDK 1.3, I suspect this is either a problem with Opera or with my having set it up wrongly. I didn't try too hard. (Opera displayed a message "The applet has crashed".) If someone out there uses Opera and can run this applet successfully, I'd like to know!