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
Andrew [12]
3 years ago
11

Checkpoint 7.61 Write the prototype for a function named showSeatingChart that will accept the following two-dimensional array a

s an argument. const int ROWS = 20; const int COLS = 40; string seatingChart[ROWS][COLS]; Note: The two-dimensional array argument must be a const string array. You must include a second integer argument (scalar, not an array).
Computers and Technology
2 answers:
Kobotan [32]3 years ago
7 0

Answer:

void showSeatingChart(const string [][COLS], int);

Explanation:

void showSeatingChart(const string [][COLS], int);

The above function showSeatingChart() will display the 2D array of seating chart.

The return type of this function is void because it does not need to retun anything.

The parameter of the function is a 2D array which is seatingChart[ROWS][COLS].

The type of this 2D array is string that means it is a 2D array of string. It will contain string elements.

To declare a prototype of a function, there should be a semi-colon (;) at the end of declaration.

The definition of the function should be given outside main() function and declaration of the function should be above the main() function or at the beginning of the program with declaration of constant variables.

New2This3 years ago
0 0

void showSeatingChart(const string [][COLS], int);

You might be interested in
How will you be assigned with a mailbox with any OSP
Leona [35]

Answer:

Go to the File tab and click Options.

Click on the Mail menu at the left.

Click on the Signatures button to open the Signatures and Stationary window.

In the Email Signature tab, click New.

Type in a name for the New Signature such as Shared Mailbox Signature and click OK.

Explanation:

3 0
3 years ago
How do you take apart a I pad and put it back together and it still works
vekshin1
I would suggest getting it checked out at the apple store doing it yourself will be quite challenging. Get it done by a professional.

8 0
3 years ago
Which of the following would not be stored in a cell ?
Andreas93 [3]

Answer:

D

Explanation:

Because you can put formulas, text and numbers into a salad, but you can not put a chart interrupt because it won't fit in a cell.

5 0
3 years ago
Write a function DrivingCost() with input parameters drivenMiles, milesPerGallon, and dollarsPerGallon, that returns the dollar
stira [4]

Answer:

// program in C++.

#include <bits/stdc++.h>

using namespace std;

// function to calculate cost

double DrivingCost(double drivenMiles, double milesPerGallon, double dollarsPerGallon){

  double cost;

  //Expression to compute cost

  cost = drivenMiles / milesPerGallon * dollarsPerGallon;

  return cost;

}

// main function

int main()

{

   double drivenMiles, milesPerGallon, dollarsPerGallon;

  //initialise the variables

  drivenMiles = 50;

  milesPerGallon = 20.0;

  dollarsPerGallon = 3.1599;

  //Call function

  double cost = DrivingCost(drivenMiles,milesPerGallon,dollarsPerGallon);

  //Display result

  cout<<"Driven miles : "<<drivenMiles<<endl;

  cout<<"Miles per Gallon : "<<milesPerGallon<<endl;

  cout<<"Dollars per Gallon : "<<dollarsPerGallon<<endl;

  cout << fixed << setprecision(2);

  cout<<"The total driving cost : "<<cost ;

  return 0;

}

Explanation:

Declare and initialize drivenMiles with 50, milesPerGallon with 20.0 and dollarsPerGallon with 3.1599.Call the function DrivingCost() with these parameters,This will calculate the cost and return the value.Print the result after getting the cost.Similarly we can calculate cost for drivenMiles equals to 10 and 400 miles also.

Output:

Driven miles : 50

Miles per Gallon : 20

Dollars per Gallon : 3.1599

The total driving cost : 7.90

5 0
3 years ago
Create a program called "Geometry" Prompt the user for a small decimal number. Prompt the user for a large decimal number. Using
skelet666 [1.2K]

Answer:

In Python:

import random

small = float(input("Small: "))

large = float(input("Large: "))

radius = round(random.uniform(small, large),2)

volume = round(4/3 * 22/7 * radius* radius* radius,2)

print("Radius: "+str(radius))

print("Volume: "+str(volume))

Explanation:

This imports the random module

import random

The next two lunes prompt the user for small and large decimal number

small = float(input("Small: "))

large = float(input("Large: "))

This generates the radius

radius = round(random.uniform(small, large),2)

This calculates the volume

volume = round(4/3 * 22/7 * radius* radius* radius,2)

This prints the generated radius

print("Radius: "+str(radius))

This prints the calculated volume

print("Volume: "+str(volume))

<em>Note that, the radius and the volume were approximated to 2 decimal places. Though, it wasn't stated as part of the program requirement; but it is a good practice.</em>

8 0
3 years ago
Other questions:
  • Telecommunications is the transmission of voice and video as well as data and usually implies transmitting a longer distance tha
    5·1 answer
  • You have just created a one-way incoming trust in your domain for an external domain used by a partner company to allow your dom
    11·1 answer
  • As it is a good practice that C# broughtback the concept of GOTO statement and Pointer? If your answer isyes then how C# control
    15·1 answer
  • A ________ is a term used to describe a select list that allows the user to select an option to load another web page.
    10·1 answer
  • Which domain ending can only be used by the U.S. government?
    14·2 answers
  • RAM that can be changed. True or False
    9·2 answers
  • Explain how to utilize the computer in rooms management.​
    13·1 answer
  • Can someone help me calculate this Multimedia math:
    11·1 answer
  • 4. Arnold curates articles that feature trending lists for an online website. His department is responsible
    5·1 answer
  • Sftp uses which mechanism to provide security for authentication and data transfer?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!