Which is best for you depends on you and your lifestyle. Cats require less care, but are very independent. Some cats will become very attached to you, but generally, they will come to you when THEY want to, not when you call them. You will generally not be able to take a cat for a walk outside or over to the local pet store when you shop. But a cat will sit in your lap, keep you warm when it's cold, and purr like crazy when you pet him. It's been said that a cat will lower your blood pressure. If you work outside of the home you won't need to worry about getting home during the day for a walk or being sure to be home right after work to feed your cat. You will need to get a litter box.
If you travel, you can leave a few days worth of food for a cat or you can have someone come in to "cat-sit" every other day or so to make sure he gets attention, to fill up the food and water bowls, and check or clean the litter box. So if you travel often or are gone for most of the day, maybe a cat is best for you.
On the other hand, a dog is trainable. You train him to go outside to take care of his bathroom needs (no litter box, though some small dogs these days have a "wee-wee pad" so that they can be left in the house while you're gone). You can train him or her to do tricks, to come when you call, to take a walk on a leash without pulling, to respond to commands and not jump on your guests when they walk in the door. You can take a dog on trips in the car. Most cats hate the car. To them it means a trip to the vet.
A dog is a social magnet for other dog lovers to stop and talk to you. He's a wonderful companion who will become one of the family. He will love you unconditionally, and forever. And you'll love him, too.
That's not to say that you won't love your cat. We still have memories of Annie, a yellow tabby cat that followed my husband a block to the mailbox and back every night. And there was Bailey, who could open doors from inside or outside a room. No locking him up while he got used to the house. But we also remember our first dog, Jet, who was sweet and loving until someone climbed our fence to check out her pups. Then she went into protection mode. And then there was Brandy, an Irish Setter, who chewed an entire couch when he was a puppy.
I would recommend checking your nearest shelter. There are many dogs and cats who wind up homeless and need someone to take care of them. When one of them looks at you and you bond immediately, take him home with you. Whichever you decide, it will be a wonderful experience filled with love and laughter.