See More Stuff

Chinese Arithmetic Game

A friend of mine, Vincent, told me that when he was a kid in China, they would play a number game with a deck of cards. You draw four cards, and try to get a result of 24 using only addition, subtraction, multiplication and division on the four numbers drawn.

For Example, if you drew 6, 4, 5, 5 you could solve it with (6*4)+5-5

He couldn't figure out if a solution was possible when given two threes and two eights, so I wrote this brute force javascript to solve the problem.