Sum of Natural Numbers
Practice
5 (1 votes)
Problem
89% Success 86 Attempts 20 Points 1s Time Limit 256MB Memory 1024 KB Max Code
Given a natural number N, find the sum of all natural numbers from 1 to N.
Sample Input
4
Sample Output
10
Explanation
For N=4, sum of all Natural Numbers from 1 to 4 is-
1+2+3+4 = 10
Code Editor
Please login to use the editor
You need to be logged in to access the code editor
Loading...
Please wait while we load the editor
Submissions
Please login to view your submissions
Similar Problems
Points:20
2 votes
Tags:
ImplementationMathematicsEasyMathematicsMathamatics
Points:20
10 votes
Tags:
ImplementationMath BasicBasics of ImplementationC++Basic MathMathGame Theory
Points:20
16 votes
Tags:
Basic ProgrammingOpenApprovedEasyMathamatics
Editorial
No editorial available for this problem.
Please login to use the editor
You need to be logged in to access the code editor
Loading...
Please wait while we load the editor