so I have this question in my homework which I don't really understand.
This is the main function that was given:
int main() {
int a = 111;
int b = 32;
int c = 89;
for(int i = 0; i < 10; i++){
shiftLeft(a,b,c);
cout << "(a,b,c) == (" << a << "," << b << "," << c << ")" << endl;
}
return 0;
}
and this is what I could only think off (it's wrong, but maybe it helps)
#include <array>
void shiftLeft(int a, int b, int c) {
int shift=3;
int x=shift-1;
int temp=array[3];
while (x >= 0 && shift >= 0) {
array[shift]=array[x];
x++;
shift++;
}
}