I was referring to men in my command in the Army. Trust me they are plenty trained.
We are talking about merchant ship here, no? I'm no longer entirely sure if you are also talking about that branch, but I assume you are, because you claim to have an easy solution to the pirate problem, and surely most of the victims of piracy are commercial vessels.
You say that we should arm the crews. But not only that: it seems you also want to train them to be well-disciplined army sailors. That makes some sense, because putting weapons in the hands of the untrained is quite stupid. However, I think doing that is a bit steep if not silly. I don't think you can expect these crewmembers to get military training to before they can become commercial sailors. But hey, perhaps they have time for training when they are on long voyages, so we can get around that argument. Ofcourse the main objection, as has been brought up: it is just very very costly.
Now let's just throw those practicalities overboard and say that the harbors can be secured and there is enough money to arm the thousands of commercial ships and train their crews. It'll take a money forrest, but let's say it is deemed worth the investment.
There are a couple of foreseeable results. First, the pirates will just get vicious. Many ships will sink when the pirates are faced with a counterfire. Second, they will attack more oil tankers and carriers of other flamable stuff. (Oh, but we're in imagination land, so let's put plates of armor on those!) Third, weapons are explosive devices, in the figurative sense as well as literally. More weapons equals more bullets being fired by or against you. It makes the entire naval scape more volatile. And weapons are items which can be lost or stolen by crew. Or by infiltrating pirates. We're dealing with commercial ships and enterprises here. Crews get on and off boats, the boats are leased to different companies, it's far more chaotically organized than a single body such as the army (which might be pretty well organized and still not entirely unchaotic, you must know).
Reality forces me back to the practicalities, which I tried to throw overboard earlier in this reply. It is just inevitable. There's problems everywhere. You need to have a really good reason for me to discard those. You haven't. Nor is your solution ethically sound.
There are 2 big problems with your way of thinking.
One: You seem to envision that honour and cowardice are players of some significance in the real world. They have no commercial value and they are not going to repel or (resp.) attract pirate renegades by themselves. Money and poverty are big players for the pirates, and has everything to do with their survival and desperation.
Two: We're not in the army! Sailors are not armed personnel. They do not like to shoot people and can't be expected to do that as part of their job description. So guns do not belong in their equipment, either. Because guns are for killing. If you insist on putting arms on board, you need to put them in the hands of army squads, with a very high chance that they will be paid and unavailable for weeks, without contributing anything. The fact that it seems an easy solution to you to just distribute guns and training, to turn normal people into killing machines such as yourself is thoughtprovoking, or so it should be. Army boy.