A question regarding the cannon on top of submarines

I seem to recall that the Japanese build some enormous submarines, which mounted large-calibre deck guns and carried seaplanes! From what I read, these big boats were not of much use…but they sure had a great range.
What was the largest pre-nuclear submarines?

Actually they weren’t all that large. The plane- singular- was disassembled and stowed in a special compartment.

The plane itself was pretty small too- I forget exactly, but I seem to recall it was a small recon type, not a fighter, equipped to carry only one or two small bombs. I get the impression it was the size of a large Cessna.

When launching, the crew hauled out the fuselage, attached the floats and wings, set it in the water and the pilot took off like any normal small seaplane.

I think that the planes the Japanese usually used via submarine were Yokosuka E14Y float planes which the Allies called “Glen.” They were primarily reconaissance, but one did try to start a forest fire in Oregon.

However, at the close of the war the Japanese were developing a larger float plane with which to attack the Panama Canal with adult-sized bombs, the Aichi M6A1 Seiran. The Paul E. Garber facility has one and is working to complete its restoration.

And yet rapid fire weapons of 20mm-40mm caliber are called “cannon”.

Probably not officially.

U.S. Navy (DoD) definition of gun (note that it is defined as a type of cannon.

The definition of gun is contrasted with the definitions of
howitzer and mortar.

There is no separate entry for cannon or for machine gun (which would be useful, for those not already aware of it, in distinguishing between a 20 mm cannon and a .50 caliber machine gun) or for rifle (which is another Navy term for the long-barreled cannons that replaced the older smoothbores).

sqweels, that was the naval definition.

I found that cannon and gun would be used to describe the same weapon in the same sentence, it’s just a case of what’s the official designation I suppose.

The difference between a cannon and machine gun is somewhat simpler. As a general rule: Cannon fire shells which explode, machine guns fire bullets, which do not.

Different services define the various weapons slightly differently, but that topic would hijack the OP even further.