Question: Write a public method named findSum that takes a a parameter named n of type int. If n is less than 1 the method returns

Write a public method named findSum that takes a a parameter named n of type int. If n is less than 1 the method returns - 1 otherwise it returns a number that is the result of applying the following formula to i values ranging from 1 to n: Note: I is the symbol for summation. n 2 n(n + 1) 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
