Opening the reading…
Opening the reading…
DSA FUNDAMENTALS › CONTROL FLOW
This is a scratch drill — your code runs, nothing is graded or recorded. No test cases, no expected output, no verdict.
TASK
Repair the loop for n = 50724 so it advances through all five digits and prints the digit sum 18. Add the statement that changes work after each digit is added to sum.
OUTPUT
Sample18
What a finished answer prints, from the lesson. Nothing has run yet — press Run and this is replaced by your program’s own output.