computer that separating what he wants that the player write

hello everyone! if anyone know, in the game of ubisoft called lost: via domus, there was a computer that ask the player to write sentences that the computer Supposed to separate if he wrote the right sentence, and if the player were write the wrong sentence it was erase the sentence because they were wrong. so that what i want to do, could someone tell me a way to do it. http://www.youtube.com/watch?v=ET2MxSgT3Cs&feature=related in this video between 1:39 to 1:52 and between 6:36 to 6:53 you see what i mean.

you need to save that input in a string and then compare with the one you want