#include <iostream>
int main()
{
double s = 0;
for(int i = 3; i <= 30; i += 3)
s += 1.0 / i;
std::cout << s;
return 0;
}
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
#include <iostream>
int main()
{
double s = 0;
for(int i = 3; i <= 30; i += 3)
s += 1.0 / i;
std::cout << s;
return 0;
}