Quizes
Problems
Courses
Sign
Register
Main
/
Courses
/
Basics of C++
/
Loop statement with condition - while
Loop statement with condition - while
№ 9
/21
Sum of digits of a number
Read Theory
Task
Time limit:
1000
ms,
Memory limit:
32 Mb
Using the previous program, change it so that it finds the sum of the digits of n.
The program should request a single number from the keyboard and display a phrase (for example, for the number 123)
The sum of the digits of number 123 is 6
Prohibited statements:
list;[
Auto
CHOOSE THE PROGRAMMING NECESSARY LANGUAGE!
Attach the program source file:
or enter the source code in the language:
C++
Python
FreePascal
PascalABC.Net
Kumir
Java
JavaScript
TypeScript
C#
F#
Swift
Rules for designing programs and a list of errors during automatic task verification
Results: