Answer:
#include<iostream>
#include<cstring>
#include <algorithm>
using namespace std;
class Student{
public:
string name;
int rollNo;
Student(){
}
Student(string n, int r){
name = n;
rollNo = r;
}
};
class ClassRoom{
public:
Student stud[10];
int count;
ClassRoom(){
count = 0;
}
void addStudent(string str,int roll){
Student s(str,roll);
stud[count++] = s;
}
Student * getAllStudents(){
return stud;
}
};
int main()
{
string name;
char temp[20];
int rollNo, N, i;
Student * students;
ClassRoom classRoom;
i=0;
while(getline(cin, name) && cin.getline(temp,20)&&i<10){
rollNo = atoi(temp);
classRoom.addStudent(name, rollNo);
i++;
}
N = i;
students = classRoom.getAllStudents();
for(int i=0 ; i < N; i++){
cout << (students+i)->rollNo << " - " << (students+i)->name;
if(i<N-1)
cout<<endl;
}
return 0;
}
Explanation:
- In the addStudent method, increment the counter and as the value of variable s to the the stud array.
- In the getAllStudents method, return all the students.
- Finally in the main method, display the name and roll no. of students.
Tech a is correct which is the correct answer
Answer:
HELP ... I WILL GIVE ALL THE POINTS IT CAN.
THE QUESTIONS ARE:
1. ACCORDING TO THE SUBCLASSIFICATION OF EACH WEB SITE AS YOU WOULD DEFINE THE TYPES OF THE WEBSITE.
2. WHAT IS THE DIFFERENCE BETWEEN EACH SUBCLASSIFICATION OF THE WEBSITES
3. LIST EXAMPLES OF EACH SUBDIVISION
THE SUBCLASSIFICATIONS IN QUESTION ARE: SITE BY HEARING, BY DYNAMISM BY OPENING, BY DEPTH AND BY OBJECTIVE
Explanation:
What is the question needed to be answered?
The first step would be knowing the manufacturer s recommended schedule for maintenance