tiannahines4504 tiannahines4504
  • 24-11-2022
  • Computers and Technology
contestada

define a function swaprank() that takes two char parameters passed by reference and swap the values in the two parameters. the function does not return any value. ex: if the input is b c, then the output is: c b

Respuesta :

NomulaHarsh NomulaHarsh
  • 26-11-2022

The program that takes two char parameters passed by reference and swaps the values in the two parameters is shown below.

What is a program?

A computer program is a set of instructions written in a programming language that a computer can execute.

The program is illustrated below:

void Swaprank(char &a1, char &a2)

{

char t = a1;

a1= a2;

a2 = t;

}

Output

B

C

C B

To know more on programming follow this link below:

brainly.com/question/26642771

#SPJ4

Answer Link

Otras preguntas

As a person pedals the bike, what forces oppose motion? As the person goes faster, what happens to the amount of air resistance?
Evaluate the function. f(x)=-3x^2-20 Find f(−7)
in describing abnormal curvatures it could be said that
in contrast to folk culture, popular culture is more likely to vary
What are the base units the SI units are based on? A-10 B-100 C-1,000 D-1
There are 9 new books and 5 used books. What is the ratio of all the books on the shelf to the new books
Read the passage below. First, identify the text structure used in the passage. Then explain how the author's use of this text structure contributes to the deve
HELPPPPPPP!!!!! PLEASEEEEEE!!!!!
In Shakespeare’s Romeo and Juliet, how do Romeo and Juliet fit the literary archetype of star-crossed lovers? Select 3 options. They are in love. Their relation
5 “able” suffix words Define and use in sentences