Need help writing a "for" loop please

Can I please get some help using the "for" loop ? I just started learning how to use C++ and I'm having trouble with this

1. Write a program to compute the sum of the terms in the following sequences. Use a for
loop:
a. 1,4,7,10,...,31
b. 2,-5,8,-11,14,...,38

c. sqrt(1),sqrt(2),sqrt(3),...,sqrt(60)
Topic archived. No new replies allowed.