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
What would this look like if you were to write the pseudocode but for c++?
makvit [3.9K]

Answer:

when make a task list you would not include commands that are for any specific language like C++

Explanation:

pseudocode should be universal. So when creating the task list, you would not include commands that are for any specific language like C++, java, C#, or perl. The point of pseudocode is to design a program that can be translated in to any language.

5 0
2 years ago
Name the cell range selected in the given worksheet? <br>plzzz helppppp​
Monica [59]

Answer:

B2:E6,,,,,,,,,,,,,,,,

6 0
2 years ago
In order to use the Active Directory Recycle Bin, all DCs in the forest must be running at least what Windows Server operating s
AleksAgata [21]

Answer:

Windows Server 2008 R2

Explanation:

The Windows Server 2008 R2 is a window server operating system that was developed by Microsoft. The server was developed on the enhancement of the Window Server 2008. This type of window server came with different improvements and benefits (such as power consumption) over the previous window servers in the market.

4 0
3 years ago
Free Brainliest Here. i Also Have A Quiz for Brainliest So Check That Out To
AysviL [449]

Answer:nice

veru cool

Explanation:

7 0
3 years ago
Read 2 more answers
Who was dobri dobrev?​
Anastasy [175]

Answer:

<h3>Dobri Dimitrov Dobrev, better known as Grandpa Dobri, Elder Dobri or The Saint of Bailovo, was a Bulgarian ascetic who walked over 20 kilometres each day to sit or stand in front of the Cathedral of Alexander Nevsky in Sofia to collect money for charitable causes.</h3>
6 0
2 years ago
Read 2 more answers
Other questions:
  • Ideally, how often should you back up the data on your computer? once an hour, once a day, once a month, once a year. Please hur
    5·2 answers
  • What to do when microsoft word is eating your words?
    8·1 answer
  • When viewing data entered into a spreadsheet, the columns identify _____.?
    5·1 answer
  • The ________ contains the central electronic components of the computer. select one:
    14·1 answer
  • What process does a system use to officially permit access to a file or a program CIS 502 ?
    11·1 answer
  • darren wants to substitute every occurence of the word bulky in his spreadsheet with the word strong. which of these options sho
    9·2 answers
  • It is easy to create good photographs of mountains because you can always tell how big they are. True False
    8·2 answers
  • Discuss the major differences in two approaches ofprogramming i.e. Object oriented programming and structuredprogramming.
    6·1 answer
  • Calculate the average high and low in python code for beginners pls
    5·1 answer
  • What operating system are you using? On most computers, you can answer this question by right-clicking on the "My Computer" icon
    6·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!