A stepping number has adjacent digits differing by exactly 1. Count stepping numbers in [L,R]. State: (pos,tight,lastDigit,started).
Transition: if ∣newDigit−lastDigit∣=1, valid. Handle leading zeros: before placing the first non-zero digit, any digit is valid. Track started flag. Examples: 123, 321, 12321 are stepping. 135, 100, 122 are not. The stepping constraint only involves adjacent digits. Track the last digit placed to check the constraint.