Here's a little mini-putt challenge for a slow (here rainy) day ... kind of an extention of the PxMagic tourney kinda ...

Object:

Given a hexidecimal number representing an RGB color, with a format like this:

&BBGGRR

where

BB = the blue color component
GG = the green color component
RR = the red color component

create a little algorithm that strips-out the three color components into seperate $vars (for example $blue, $green, $red) as a number from 0 to 255 ...

For example, I give you the color YELLOW specified in BGR like this:

&00FFFF

and you give me:

$blue = 00
$green = FF (255)
$red = FF (255)

Don't want it as a UDF, just want some statements of code ... like to see who can get it down to the fewest statements, $vars should be dimmed though.

-Shawn