Skip to content

Instantly share code, notes, and snippets.

@davidrobles
Created November 8, 2012 23:12
Show Gist options
  • Save davidrobles/4042515 to your computer and use it in GitHub Desktop.
Save davidrobles/4042515 to your computer and use it in GitHub Desktop.
Printing Othello bitboards
public static void printBitBoard(long bitboard)
{
for (long i = 0; i < Othello.NUM_SQUARES; i++)
{
System.out.print(((bitboard & (1L << i)) != 0) ? " X " : " - ");
if (i % Othello.SIZE == Othello.SIZE - 1)
System.out.println();
}
System.out.println("\n");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment