hw problems

1.

Write a C++ expression for the following algebraic expression.
c = a^3 / (b^2k^4)


2.

What is the output of the following code?
#include <iostream>
using namespace std;
int main()
{
long x, y, z;
x = y = z = 4;
x += 2;
y -= 1;
z *= 3;
cout << x << " " << y << " " << z << endl;
return 0;
}


3.

__________ reads a line of input, including leading and embedded spaces, and stores it in a string object.
Last edited on
qwert123 wrote:
1.

Write a C++ expression for the following algebraic expression.
c = a^3 / (b^2k^4)


2.

What is the output of the following code?
#include <iostream>
using namespace std;
int main()
{
long x, y, z;
x = y = z = 4;
x += 2;
y -= 1;
z *= 3;
cout << x << " " << y << " " << z << endl;
return 0;
}


3.

__________ reads a line of input, including leading and embedded spaces, and stores it in a string object.

Don't cheat. Fail the quiz/test like a man. :-P
Last edited on
Topic archived. No new replies allowed.