No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
I built a program that is supposed to read in a data file that looks like this for example: 1 2 3 4 5 6 2 3 4 9 8 7 1 6 5 7 4 2 1 3 4 5 6 7 2 5 7 8 3 1 3 … | |
I cannot figure out what this error message means? [code] #include <iostream> using namespace std; double max_array(const double x[], int max_val); int main (void) { int i, max_val; double x[max_val]; double array_avg, array_max, array_min; cout<<"Enter likely number of values: "; cin>>max_val; cout<<"Enter values seperated by white space:"; for (i=0;i<max_val;i++) cin>>x[i]; … | |
I need help with understanding how to fix my for loop and the if tests. Originally, in the for loop, for the end value i had k<=3..but this is wrong because i need to loop to keep going until it passes the test. So i was told to try setting … |