1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
ycow [4]
3 years ago
11

A Function checkMe takes three parameters, a character and two integers. If the sum of the two integers is negative, and the cha

racter has the value 'n', the function sets the integers to zero so that when the function returns, those integers have a zero value in the caller (main) program. Otherwise the function changes the character to a 'p' (so that it is changes in the caller), no matter what it started with! Give a SAMPLE CALL from main, a prototype and a function definition for this function.

Computers and Technology
1 answer:
Paul [167]3 years ago
7 0

Answer:

Check the explanation

Explanation:

Here is the program with function definition and two sample calls.

Code:

#include <iostream>

using namespace std;

//checkMe FUNCTION which takes values a, b and c

void checkMe(char &a, int &b, int &c)

{

//if sum of b and c is negative and a is 'n', b and c are set to 0, otherwise a is set to 'p'

if((b+c)<0 && a=='n')

{

b = 0;

c = 0;

}

else

{

a = 'p';

}

}

int main()

{

//first test case when else part is executed

char a = 'n';

int b = 5;

int c = 6;

 

checkMe(a, b, c);

 

cout<<a<<" "<<b<<" "<<c<<endl;

 

//second test case when if part is executed

a = 'n';

b = -4;

c = -5;

 

checkMe(a, b, c);

 

cout<<a<<" "<<b<<" "<<c<<endl;

return 0;

}

Kindly check the Output below:

You might be interested in
Which of the following items will you use to store your digital portfolio? A. notebook B. file C. flash drive D. folder
AnnZ [28]

Answer:

C)

Explanation:

that what i would use

3 0
3 years ago
Read 2 more answers
Install hardware, install software, and convert data are the three steps found in the _____. Select one:
aev [14]

Answer:b)Conversion plan.

Explanation:Conversion plan is type of plan in which the the technique is followed by converting the data from the present system to another system's hardware and software surroundings.

The technique follows three basic steps in the conversion plan is software installation plan, hardware installation plan and conversion of data. Thus the correct option is option(b).

3 0
4 years ago
Uppose a computer processor can perform about 3.8 billion operations per second. how many operations can it perform in 0.6 ​seco
Ratling [72]
We have information:
3.8 billion         1 second
x billion            0.6 second

To find out the number of operations we need to cross multiply these equations and solve for x.
3.8 * 0.6 = 1*x
x = 2.28 billion

In 0.6s computer can do 2.28 billion operations.
4 0
3 years ago
Read 2 more answers
Which software application should be used to create a sales pitch to a group of people? Database Email Presentation Word process
Bogdan [553]
Hello,

The answer is option C "presentation".

Reason:

The answer is option C presentation because presentations are used in order to show businesses sales pitch or there products in order to get a investment.

If you need anymore help feel free to ask me!

Hope this helps!

~Nonportrit
7 0
3 years ago
What is the command to list the contents of directors in Unix- like operating system
maks197457 [2]

Answer:

Ls command

Explanation:

The command to list the contents of directory in Unix- like operating system is "Ls command."

In computer programming, the "Ls command" is commonly found in the EFI shell and other environments, including DOS, OS/2, Microsoft Windows, Matlab and, -GNU Octave.

The "Ls" command is used in writing to the standard outcome, such as the contents of each specified Directory or any other information

3 0
3 years ago
Other questions:
  • Honestly reporting experimental findings is an example of good what?
    7·2 answers
  • Does any body like animal jam
    11·2 answers
  • Which of these network connections would allow your smartphone to sync your photos to your online account? Choose all that apply
    8·1 answer
  • Consider the following high-level recursive procedure: long long int flong long int n, long long int k long long int b b k+2; if
    9·1 answer
  • A virus that is embedded in the automatically executing scipts commonly found in word processors, spreadsheets, and database app
    13·2 answers
  • An option button is<br>​
    14·2 answers
  • What is the full form of 'Rom<br>​
    7·2 answers
  • Your one output statement should occupy two lines in your program
    13·1 answer
  • 8.10 Code Practice Question 3
    6·1 answer
  • Who is responsible for maintaining, monitoring, and analyzing database security at the back end?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!