Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace ConsoleInputOutput
- {
- public static class SumOfN
- {
- public static void Main()
- {
- long n = long.Parse(Console.ReadLine());
- long sum = 0;
- long number = long.MinValue;
- for (int i = 0; i < n; i++)
- {
- number = long.Parse(Console.ReadLine());
- sum += number;
- }
- Console.WriteLine(sum);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement