Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Online C++ Compiler. Code, Compile, Run and Debug C++ program online. Write your code in this editor and press Run button to compile and execute


Online C++ Compiler.
Code, Compile, Run and Debug C++ program online.
Write your code in this editor and press "Run" button to compile and execute it.

*******************************************************************************/

#include
using namespace std;
int main()
{
int sum=0;
cout<<"Part-a";
cout<<"--------------";
for(int n=4;n<=9;n++)
{
sum += 7 * (n-3);
}
cout<<"Sum = "<

// part b
cout<<"Part-b";
cout<<"--------------";
for(double n = 1; n < 8; n++)
{
cout << n << ": " << n / (n * n) << endl;
}

cout<<"Part-c";
cout<<"--------------";
sum = 0;
for(double n = 4; n < 10; n++)
{
sum += 7 * (n - 3);
}
cout << sum << endl;
cout<<"Part-d";
cout<<"--------------";
for (int row = 1; row <= 4; row++)
{
for (int col = 1; col <= row; col++)
{
cout << "*";
}
cout << endl;
}
return 0;
}



my professor what me to used POW() function in my code i dont know how to put it in I NEED HELP

he also want me to to indent properly

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Managerial Accounting Tools for business decision making

Authors: Jerry J. Weygandt, Paul D. Kimmel, Donald E. Kieso

5th edition

470506954, 471345881, 978-0470506950, 9780471345886, 978-0470477144

Students also viewed these Programming questions

Question

What are three disadvantages of using the direct write-off method?

Answered: 1 week ago