Answer:
#include <iostream>
#include <iomanip>
#include <string>
using namespace std;
int main() {
string name[5];
int age[5];
int i,j;
for ( i = 0; i<=4; i++ ) {
cout << "Please enter student's name:";
cin >> name[i];
cout << "Please enter student's age:";
cin >> age[i];
}
for (i=0;i<=4;i++){
cout<<"Age of "<< name[i]<<" is "<<age[i]<<endl;
}
}
Output of above program is displayed in figure attached.
Answer:
Alice is correct.
The loop are dependent.
Explanation:
for(i = 1; i <= N; i = (i*2)+17 )
for(k = i+1; k <= i+N; k = k+1) // notice i in i+1 and i+N
printf("B")
This is a nested for-loop.
After the first for-loop opening, there is no block of statement to be executed rather a for-loop is called again. And the second for-loop uses the value of i from the first for-loop. The value of N is both called from outside the loop.
So, the second for-loop depend on the first for loop to get the value of i. For clarity purpose, code indentation or use of curly brace is advised.
Answer:
Welding, carpentry, masonry, construction worker, barber
Explanation:
Answer:
Mechanical average of a wheel = 3
Explanation:
Given:
Radius of wheel = 1.5 ft = 1.5 x 12 = 18 inches
Radius of axle = 6 inches
Find:
Mechanical average of a wheel
Computation:
Mechanical average of a wheel = Radius of wheel / Radius of axle
Mechanical average of a wheel = 18 / 6
Mechanical average of a wheel = 3
Answer:
The answer is 0.727
Explanation:
lemme know if that's right