Most modern blued steel firearms are manufactured from "medium" carbon steel, usually 4340, often called chromoly steel. Additives (aproximate)in 4340 are Carbon .40, Manganese .70, Phosphorus .035max, Sulphur .04 max, Silicon .15-.35, Chromium .80, Nickel 1.80, Molybdenum .25.
Most modern "stainless" steel firearms are manufactured from type 410 steel. Additives (again aproximate) in 410 are Carbon .15 max, Manganese 1.00 max, Phosphorus .04 max, Sulphur .03 Max, Silicon 1.00 max, Chromium 11.5-13.5.
The term "stainless" is relative. Stainless steels are usually many times more resistive to corroding agents, generaly their corrosion resistance is porportional to the relative Chromium content.
Stainless is primarily used in the food industry; many food stuffs contain agents that attack carbon steels. Much used in the aircraft industry where corrosion resistance at elevated temperatures is desired. Stainless has considerably lower yield strength than carbon steel but it retains it's original strength to higher temperatures.
Stainless has many decorative uses due to it's lack of need for protective finishes.
In most applications the sacrifice of strength for corrosion resistance is a worthwhile trade off for the end user.
With proper care, blued steel gun should outlast stainless gun. Not counting wear of the external finish on blued gun.
Sam