Computer Science, asked by shreyagaurav45, 8 months ago

write a program to print the series 0,1,1,2,3,4,5....n​

Answers

Answered by Anonymous
3

Answer:

class Series { public static void main(int n) { int add=0; for(int i=2;i<=n;i=i+2) add=add+(i*i); System.out.println(add); } }

Similar questions