Write a definition for a void-function that has two int value parameters and outputs to the screen the product of these arguments. Write a main function that asks the user for these two numbers, reads them in, calls your function, then terminates.

What will be an ideal response?


```
//file: testProblem.cc
//illustrates value parameters in a void-function,
//fetching values, and the calling of that function
//to multiply and display arguments.
#include
using namespace std;
void func(int x, int y)
{
cout << x * y << endl;
return;
}
int main()
{
int f, g;
cout << "Enter two integers, I'll return the product.&endl;
cin >> f >> g;
func(f, g);
return 0;
```

Computer Science & Information Technology

You might also like to view...

Gradient swatches are stored on the ____________________ panel.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

What is the difference between lossless compression and lossy compression? Which type of sound files use what type of compression?

What will be an ideal response?

Computer Science & Information Technology

You can navigate a datasheet much like you navigate a PowerPoint slide show.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

Identify a pop-up window that is used to display a message.?

A. ?Alert box B. ?Combo box C. ?Off page window D. ?Checkbox

Computer Science & Information Technology