This sheet works a 40" deck two ways. Option A uses the fewest risers the IRC allows, 6 at 6-11/16" on 10" treads. Option B adds one riser and uses 11" treads for a gentler 5-11/16" step. Both come with hook-once tape marks for the stringer edge, below the calculator.
Option A: 6 risers at 6-11/16"
40" ÷ 7.75 = 5.16, rounded up to 6 risers, each 6-11/16"− (6.6667", 169.3 mm). On 5 treads of 10" the stair lands 50" (4' 2") out from the deck and climbs at 33.7°; 2R + T scores 23.33".
Each step is 12"+ along the stringer edge. Notches cut 5-9/16" deep, leaving 5-11/16" of throat in a 2x12; the cut length is 5' 3-1/4", so buy 8 ft stock.
Option B: 7 risers at 5-11/16"
One more riser drops each step to 5-11/16"+ (5.7143"). With 11" treads the run grows to 66" (5' 6"), 16" more than Option A, and the angle eases to 27.5° with 2R + T at 22.43".
The diagonal is 12-3/8"+, the throat 6-3/16", and the stringer cut length 6' 4-9/16" (8 ft).
Cutting the bottom and the top
Take the tread thickness off the bottom riser: 6-11/16" becomes 5-11/16" under 1" 5/4 or composite treads, 5-3/16" under 1-1/2" 2x6 treads. Every finished step then measures 6-11/16".
At the top, the last tread notch sits 7-11/16" below the finished deck for 1" treads. Hung flush from the rim, the stringer edge meets the rim face 1" below the finished deck surface.
Code notes for this deck
6 risers means a handrail is required (four or more risers), 34" to 38" above the nosings.
At 40" the open sides need a guard: 34" above the nosings, no opening wider than a 4-3/8" sphere, and the tread-riser triangle under 6".
The 50" run is within the 6'-0" a cut 2x12 stringer may span under DCA 6, so no mid-support is needed.