
Compared to the JSF, the F-22 Raptor is indeed larger in size and internal volume. Nevertheless, the F-22 suffers from one key limitation. Its center bays were designed around the AIM-120 AMRAAM that is only about 12 ft (3.65 m) in length and has a maximum fin span of about 1.5 ft (0.45 m). These dimensions are quite sufficient for the aircraft's primary role as an air superiority fighter. However, the end of the Cold War forced the Air Force to change priorities and give the F-22 a stronger ground attack capability. Unfortunately, most air-to-ground weapons are significantly longer, wider, taller, and heavier than the AIM-120, making it difficult to integrate such weapons into the F-22 bays. The only weapon that has been integrated so far is the GBU-32 JDAM, a GPS-guided bomb that is about 10 ft (3.05 m) in length and is based on the 1,000 lb (455 kg) Mk-83 general purpose bomb.
Most air-to-surface weapons are in the 2,000-lb (910 kg) class, however, but these weapons are usually around 12.5 to 14 ft (3.80 to 4.25 m) long and too large to fit within the F-22. Bearing these limitations in mind, JSF designers purposefully sized the two internal bays around these larger 2,000-lb class weapons. The two weapons that have predominantly dictated the overall length and depth of the bays are the AGM-154 JSOW and the GBU-31 2,000 lb (910 kg) version of JDAM.

F-35 internal weapons
Most air-to-surface weapons are in the 2,000-lb (910 kg) class, however, but these weapons are usually around 12.5 to 14 ft (3.80 to 4.25 m) long and too large to fit within the F-22. Bearing these limitations in mind, JSF designers purposefully sized the two internal bays around these larger 2,000-lb class weapons. The two weapons that have predominantly dictated the overall length and depth of the bays are the AGM-154 JSOW and the GBU-31 2,000 lb (910 kg) version of JDAM.

F-35 internal weapons
Not included in this diagram are weapons in source selection as of this writing that are to be added to the internal carriage list. These weapons include the American GBU-39 Small Diameter Bomb, of which four can be carried on the air-to-ground station in each bay, and a new 500 lb laser guided bomb for the British (ultimately won by the Paveway IV). Another possible addition is a new variant of JDAM being considered by the US that will add a digital scene matching capability for improved accuracy.
The F-35 also has six external pylons, three under each wing. The inboard station is designed for up to 5,000 lb (2,265 kg) loads and will most likely be used to carry external fuel tanks. The pylon can carry 2000-lb class air-to-ground weapons as well. The midboard pylon is also primarily intended for air-to-ground weapons and can carry up to 2,500 lb (1,135 kg). The surface attack weapons compatible with these two pylons include many of the same ones carried internally as well as additional stores that are too large to fit in the bays. The outboard station on each wing, however, is a dedicated air-to-air station carrying up to 300 lb (135 kg) and designed specifically for short-range infrared guided missiles like AIM-9X Sidewinder. A list of weapons currently planned for external carriage is illustrated below. Note that training bombs have not been included in this list.
The F-35 also has six external pylons, three under each wing. The inboard station is designed for up to 5,000 lb (2,265 kg) loads and will most likely be used to carry external fuel tanks. The pylon can carry 2000-lb class air-to-ground weapons as well. The midboard pylon is also primarily intended for air-to-ground weapons and can carry up to 2,500 lb (1,135 kg). The surface attack weapons compatible with these two pylons include many of the same ones carried internally as well as additional stores that are too large to fit in the bays. The outboard station on each wing, however, is a dedicated air-to-air station carrying up to 300 lb (135 kg) and designed specifically for short-range infrared guided missiles like AIM-9X Sidewinder. A list of weapons currently planned for external carriage is illustrated below. Note that training bombs have not been included in this list.
You also ask about whether the aircraft has a gun, and the answer depends on what variant you ask about. The Air Force's CTOL model is the only version carrying an internal gun. The GAU-12 25-mm cannon is mounted above the engine inlet on the left side of the plane, as shown in the diagram below.

The weapons industry’s concern about belt-tightening notwithstanding, the military budget is likely to continue its dramatic growth. The Defense Department’s base budget, which does not include funds for nuclear weapons or the $12-billion-a-month “war on terror” has grown by nearly 70% – from $316 billion in 2001 to a request for more than $515 billion for 2009’s fiscal year (which begins in October).

Despite the fact that these figures represent close to what the rest of the world combined devotes to the military, neither Obama nor McCain has adopted reducing military spending as part of his national security plan. In fact, as both of them talk about modernizing the military for the 21st century and expanding the size of the armed forces, the billions add up.

