Northrop Grumman's primary goal for the B-2 was stealth, or low observability. Simply put, stealth is the ability to fly undetected through enemy airspace. Ideally, a stealth aircraft will be able to reach and destroy desired targets without ever engaging the enemy in combat.
To do this, the aircraft needs to be nearly invisible in a number of different ways. Obviously, it needs to blend in with the background visually, and it needs to be very quiet. More importantly, it needs to hide from enemy radar as well as infrared sensors. It also needs to conceal its own electromagnetic energy.
The B-2's flat, narrow shape and black coloration help it fade into the night. Even in the daytime, when the B-2 stands out against blue sky, it can be hard to figure out which way the plane is going. The B-2 emits minimal exhaust, so it doesn't leave a visible trail behind it.
As with most planes, the B-2's noisiest component is its engine system. But unlike a passenger jet or B-52, the B-2's engines are buried inside the plane. This helps muffle the noise. The efficient aerodynamic design helps keep the B-2 quiet as well, because the engines can operate at lower power settings.
The engine system also works to minimize the plane's infrared (heat) signature. Infrared sensors, including those on heat-seeking missiles, typically pick up on hot engine exhaust. In the B-2, all of the exhaust passes through cooling vents before flowing out of the rear ports. Putting the exhaust ports on the top of the plane further reduces the infrared signature, since enemy sensors would most likely scan below the plane.