Dogs lick people's hands for different reasons, but generally, they do it out of love. Your dog isn't testing the waters to see if you would make a tasty snack -- he just wants to show you his love and trust while engaging in a simple pleasure. His licking behavior may puzzle you as a human, but to dogs, licking hands just makes sense.
Forget the psychological and instinctive motivations behind hand licking -- some dogs just do it because they like the taste. If you don't wash your hands after cooking or eating, your dog may want to lick them clean for a sample of that oh-so-delicious "people food." Even if you don't have food on your hands, the natural oils, salt and sweat that collect on your hands over the course of a day can taste irresistible to a dog, and he'll want to lick it right off.
Dogs in the wild live in packs, and packs have their own rules and group behaviors. While the pack functions as a whole, there is generally a leader in the pack who has established dominance. It isn't unusual, then, for the rest of the dogs in the pack to lick the dominant dog as a sign of submission, trust and obedience. Since you are the leader of your "pack," your dog may feel compelled to lick you as a sign of his submission.
Affection and Relaxation
If you've ever been a nail-biter, you may understand why your dog licks your hands. Licking your hands can give your dog a simple sense of satisfaction and stress relief, because it releases endorphins. It's the same thing that happens when you bite your nails or exercise -- when your body releases the endorphins, a sense of calm pleasure washes over you. It's a simple, methodical, therapeutic behavior that your dog just plain enjoys.
Some dogs develop compulsive behaviors because they find them comforting, much in the same way that humans do. This has less to do with the release of endorphins than it does the satisfaction of an inexplicable urge, like how a person may feel compelled to pluck his own hair or pick at his own skin. If your dog refuses to stop licking your hands, you may need to consult a canine behaviorist who can determine the root of the behavior -- sometimes dogs develop compulsions as a coping mechanism after past traumas or current unhappiness.