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
Minchanka [31]
3 years ago
15

class student_record { public: int age; string name; double gpa; }; Implement a void function that has five formal parameters: a

dynamic array of student_records, the count (number of student_records in the array), an integer, a string, and a double. The function will delete a student record in the dynamic array with age, name and gpa fields that match the age, name and gpa fields that are given in the formal parameters. Remember, to check to see if the dynamic array is empty because you cannot delete from an empty array.
Computers and Technology
1 answer:
Setler79 [48]3 years ago
8 0

Answer:

void delete_record(student_record *arr, int &size, int age, string name, double gpa) {

int index = -1;

if (arr != NULL && size > 0) {

for (int i = 0; i < size; ++i) {

if (arr[i].age == age && arr[i].name == name && arr[i].gpa == gpa) {

index = i;

break;

}

}

}

if (index != -1) {

for (int i = index; i < size - 1; ++i) {

arr[i] = arr[i + 1];

}

size--;

}

}

You might be interested in
Plz help
Rama09 [41]

Answer:

name

Explanation:

name =

is an assignment to the variable called 'name'.

5 0
3 years ago
Read 2 more answers
your brother has made a battery operated torch by using 2 cells &amp; has come to ask you how he may make the torch more powerfu
torisob [31]

Answer: Add more cells in series.

Explanation:

Adding more cells in series will add voltage which will increase the power.

5 0
3 years ago
The speed density fuel injection system uses the blank sensor as the primary sensor as the primary sensor to determine base puls
aivan3 [116]

Answer:

A) Map

Explanation:

All gasoline (petrol) fuel systems need ways or method that will be calculating amount of the air that is entering the engine.This is true as regards mechanical fuel injection, carburetors and electronic fuel injection.Speed density system fall under one of this method. "Speed" in this context means the speed of the engine while "density" means density of the air. The Speed is been measured using the distributor, crankshaft position sensor could be used here. The Density emerge from from measuring of the air pressure which is inside the induction system, using a typical "manifold absolute pressure" (MAP) sensor as well as air temperature sensor. Using pieces of information above, we can calculate

mass flow rate of air entering the engine as well as the correct amount of fuel can be supplied. With this system,

the mass of air can be calculated. One of the drawback if this system is that

Any modification will result to incorrect calculations. Speed-Density can be regarded as method use in estimation of airflow into an engine so that appropriate amount of fuel can be supplied as well as. adequate spark timing. The logic behind Speed-Density is to give prediction of the amount of air ingested by an engine accurately during the induction stroke. Then this information could now be used in calculating how much fuel is required to be provided, This information as well can be used in determining appropriate amount of ignition advance. It should be noted The speed density fuel injection system uses the Map sensor as the primary sensor to determine base pulse width

7 0
3 years ago
I need help can yall help me
AnnZ [28]
8.75
I think this is the answer. The way you solve this is you divide 175 by 20 and then you have the answer.

7 0
3 years ago
Read 2 more answers
4. Software, biotechnology, and information technology hardware industries are examples of the type of knowledge industry A.mana
motikmotik
D.Has knowledge as its product?

6 0
4 years ago
Other questions:
  • Keeping in mind the role the order of precedence plays in equations, what would Excel display as the result of the following equ
    14·1 answer
  • What is the numerical ratio that is equivalent to 19.2 dB?
    14·1 answer
  • I have an airsoft pistol and I needed to take it apart to repair it and I lost some screws that were tiny and I dont know what t
    14·1 answer
  • your computer running Windows 10 is doing some very strange things with operating system you are fairly certain it is not a hard
    13·2 answers
  • Who was the founder of the location-sharing site Whrrl
    6·1 answer
  • What factors do network consultants consider when determining the network needs of a business? Use the space provided below to a
    6·1 answer
  • 80. A .......... is used to read or write data.<br>A. CD B. VDU C. ROM D. RAM​
    6·1 answer
  • Where can elicitation techniques be used?
    12·1 answer
  • Type the correct answer in the box. Spell all words correctly.
    13·1 answer
  • Chang investigates ways to improve the interactivity of computer hardware. His job title is best described as ✓ Computer and Inf
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!