105k views
5 votes
Suppose you attend a party. To be sociable, you will shake hands with everyone else. Write the algorithm that will compute the total number of handshakes that occur. (Hint: Upon arrival, each person shakes hands with everyone who is already there. Use the loop to find the total number of handshakes as each person arrives.)

User IVerzin
by
5.1k points

1 Answer

7 votes

Answer:

Following are the flowchart to the given question:

Step-by-step explanation:

Suppose you attend a party. To be sociable, you will shake hands with everyone else-example-1
User TLadd
by
5.3k points