Popularized in the mass media as illegal, card counting is a card game strategy where a player tries to decide when they have a probability advantage over the house.
This strategy is often used in Balck Jack where players try to keep track of high cards to low cards ratio.
While using devices like iPhone (which has a card counting application) for counting, mind techniques are perfectly legal, countrary to the popular belief.
Of course, casinos are also free to try and distract players who count cards by means of staff members who talk to them and engage them in a conversation.
Card counting has a mathematical background and was invented by a mathematician Edward O. Thorp in 1962. He wrote a book called "Beat the Dealer" which dealt with Black Jack strategies.
Card counting was popularized by movies like 21.
You can stay of in and try some of the best online casinos at Gambling Planets website.