| shibby4555 (3) | |||
|
Help guys, got this due in a couple hours and it is driving me nuts. I can't figure out the problem. I need to shift the values of 4 integers. I don't understand what I am doing wrong here. Below is the exact error I am getting. If you notice anything wrong I am doing please say so. I am very unskilled in this sort of stuff. Thanks for the feedback and assistance guys. ../shift_2.cpp:35:7: error: no match for βoperator<<β in βstd::cin << input1β
EDIT: I'm an idiot. Wrong arrows for cin. Still having issues with /shift2/Debug/../shift_2.cpp:26: undefined reference to `show_results(int, int, int, int)'
| |||
|
Last edited on
|
|||
| vlad from moscow (3110) | |
|
Instead of cin<<input1<<input2<<input3<<input4; shall be cin>>input1>>input2>>input3>>input4; | |
|
|
|
| vlad from moscow (3110) | |
|
At first you declared the function as void show_results(int output1, int output2, int output3, int output4); but then you defined it as void show_results(int output1, int output2, int& output3, int& output4) { | |
|
|
|
| guestgulkan (2830) | ||||
when you wrote the function declaration (on line 15) you said:
but when you wrote the function body (starting on line 48) - you wrote
| ||||
|
|
||||