Simple Flashgame? fastest wins

Hey!

I wanna do a simple game which should look something like this:

1. A random numbergenerator that generates value X
2. User A & B choose a value
3. Which one of A or B in the fastest to choice a value?
(Let say that A was the fastest)
4. A = True (X) False (E, B, C, T) Is A:s value the same as the generator value (X)?
5. IF TRUE: A wins
- IF FALSE: B wins

Is’t possible to make in AS3? Anyone know how to do it? Or can link me something which can be useful for me?

Thank you!