According to The Daily Puppy, two male puppies can typically live together without conflict. Two older males may be inclined to fight, but conflict can be avoided if the dogs are neutered and properly socialized.
Getting dogs neutered alters their behavior and makes them less aggressive. Owners should let the dogs determine, among themselves, who is the alpha. Some dogs are naturally submissive, so it may take only a few small fights to figure out which is which. Unless the fights get violent, owners should not intervene. Allowing dogs to spend time with other dogs teaches them how to behave in social situations.