#P2560. Sum of the First N Natural Numbers
Sum of the First N Natural Numbers
Sum of the First N Natural Numbers
Given a positive integer \( n \), compute the sum of all natural numbers from 1 to \( n \). The sum can be calculated using the formula: \( S = \frac{n(n+1)}{2} \).
Your task is to output the computed sum.
inputFormat
The input consists of a single line containing a positive integer \( n \).
outputFormat
Output a single integer representing the sum of the first \( n \) natural numbers.
sample
1
1