The true catapult is torsional design, which works by bending back and releasing an arm.
The so-called tensional catapult, which works very much like a giant crossbow, is more correctly referred to as the ballista and was developed prior to the torsional catapult. A small simple version is used as a toy.
The trebuchet, sometimes incorrectly referred to as a catapult, uses a counterweight rather than torsion or tension and essentially works like a giant sling. The trebuchet can be much more accurately aimed than a torsional or tensional catapult.
The first catapults appear in later Greek times, early adopters being Dionysius of Syracuse, Onomarchus of Phocis, and Alexander the Great, who introduced the idea of using them as cover on the battlefield as well as in sieges. They were more fully developed in Roman and Medieval times, the trebuchet being introduced a relatively short-time before the advent of gunpowder, which made the catapult more or less obsolete. Catapults were usually assembled at the site of a siege, and an army carried few or no pieces of it with them.
The name catapult is also given to devices used to launch aircraft off ships, in particular aircraft carriers.