Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

The program says my destination is to small. I think I need to float the ID numb

ID: 3647006 • Letter: T

Question

The program says my destination is to small. I think I need to float the ID numbers.

It states stack around hours corrupted.


#include <iostream>
#include <cmath>

using namespace std;

int main ()

{

const int empID [7]= {5658845, 4520125, 7895122, 8777541,
8451277, 1302850, 7580489};


int hours [7];
double payRate [7];
double empWages [7];

//Set the desire output formatting for numbers

//Get the employee ID
cout << " Enter the employees hours." << endl;
cin >> hours [7];
cout << " Enter the employees pay rate. " << endl;
cin >> payRate[7];

empWages [7] = hours [7] * payRate [7] ;

cout << empWages [7] << endl;

}






Explanation / Answer

i think error in ur programme is that when u re entering the employees data u need to use the for loop or while loop you are not using any loop in this programme to enter the data of employees due to which only one employee can give its data and ur destination becoming small