In Charlie and the Chocolate Factory (specifically the film), Mike brags (sort of) about the fact that he cracked the code for the Golden Tickets. He then explains that he hates chocolate. Why, then, did he crack the code? Is there any evidence that he liked other confectionary or was challenged by his friends to do it? I'd prefer a reason supported by evidence from the original book, then the 2005 film, and at last resort the original Willy Wonka film with Gene Wilder.
There is no indication as to how Mike Teevee/Teavee managed to secure his ticket in either of the other two main sources; the original Roald Dahl books or the 1967 Gene Wilder film.
The decision to make Mike an angry (but brilliant) techno-nerd appears to have been taken by the 2005 film's writer John August and is an original creation for the Tim Burton film.
Given that we're shown his obsession with video gaming, it's reasonable to assume that he saw locating the ticket as an intellectual challenge on a par with the sorts of puzzles you get in computer games and nothing more.
UPDATE : I asked the film's scriptwriter John August (via twitter) why he'd chosen to present Mike Teavee this way. He's confirmed my original assumption:
As I see it, this is the main theme of the whole story.
To do something, but do not want it from the heart.
The four children (in the movie 2005) that found a ticket (without Charlie) did it all because of base motives.
One because he is greedy/hooked on chocolate. (I assume he even did not taste it anymore).
One because her mother suggested it and she was trained to master every challenge, but she even say, that she not like chocolate.
One because she want to have everything, that makes her special and envied by other children.
And Mike TV because it was on the TV and he is intelligent enough and has no other things to do, as to solve the puzzle, which way in which store the tickets would probably take, and where he has to buy a chocolate. And by proofing his theory, he "accidentally" get one ticket...
Only Charlie want to have this ticket, because he want to see the factory! (And if one is extra precise, not because he want to see it, but because he want to show it to his grandfather).
I think he wanted to go to the factory. Then he figured out that the most likely way to get a golden ticket was to check the manufacturing dates. Since he was playing video games, he got smart and was able to think of that idea. He got so smart even that he felt like you could be smart enough to figure that out which was beyond the skills of the other 4 children who went to the factory and were probably normal people and still be a retard. I think they made it so that he hated chocolate and ending up getting only one to demonstrate how powerful that trick was.