+ 1
How we find the sum of nth term ???
🙏📝📝
8 Answers
+ 3
Abhishek Gupta
There are 2 main ways, in programming:
-use for or while loops to sum a variable to its consecutive value, starting from 1 and going to n.
-use the mathematical identity:
Sn = n(n+1)/2
Where Sn is the sum of all the natural numbers up to n.
+ 3
Try searchbar for consecutive numbers.
+ 2
I suppose the task is to demonstrate the usage of loops.
Again, please TAG THE RELEVANT PROGRAMMING LANGUAGE.
+ 1
Do you mean the sum of all integers until n?
By writing code!
If you need help, please tag the relevant programming language and give a complete task description.
+ 1
I mean that the sum of all natural no. up to nth
+ 1
Please, tag program language and show us your try
0
Hi! your question is unclear. could you ask it again (edit it) and make it clearer?
0
How to use the Sololearn searchbar
https://code.sololearn.com/W995A7y40Dow/?ref=app