need help figuring algorythm

ok suppose I want to list the hex values of the 2.5 million colors that there are, in order. (I wish to create a database where each row contains a hex color value), can anyone help me figure out the algorithm?

In order? In what order? In order like this?

for(int i=0; i<0xFFFFFF; i++)
{
  System.out.println("Color is "+i);
}

I wish to create a database where[…]

Seriously… why? :slight_smile:

[quote]…2.5 million colors that there are, …
[/quote]
How do you get 2.5 million colors from? If you use 3 components with 8 bit each you get 16 million colors.

yeah I kind of figured it out at 2 am. Thanks for the replies. :slight_smile: