C++ program to print the addition of N numbers
kw.cpp
Output
kodingwindow@kw:~$ g++ kw.cpp
kodingwindow@kw:~$ ./a.out ——————————————————————————————————————————— Program to print the addition of N numbers ——————————————————————————————————————————— Enter the number 10 The sum of first 10 natural numbers is = 55 ——————————————————————————————————————————— kodingwindow@kw:~$
What Next?
C++ program to print the floating-point numbers
C++ program to print the square of the numbers
C++ program to find the factorial of a given number
Advertisement