My daughter developed this problem when she was one years old at nursery. She started hitting other children just to get a reaction. That's when they started disciplining her - everytime she did it, they would tell her to apologise and then put her in a highchair for a minute, then take her out and give her a hug.
I actually got very worried because even in the park, she would go running to any random kid and push them or poke their eye to see what they do - so I would have to have a stern whisper in her ear everytime she was about to go running to another ride and remind her not to hit anyone or we would leave.
TBH, the disciplining may have worked in nursery because its such an enclosed environment, the kids all want to carry on playing, so they dont make the same mistake again - but at home its much harder - especially if its an only child! My daughter grew out of this by the time she was about 2. I took her to the park one day, and she didnt hit anyone - I was so happy!
I wouldnt worry too much - it is just a phase, and once they get older, with proper discipline, they learn what they're doing is wrong and not acceptable. Children are never too young for discipline - if they can understand when their food is coming, or if they are hurt, then they can be told not to hit anyone, and that it makes other children sad.