I recently ran into this riddle:
int main(){ int arr[7]; int b,c,d,a; a=4; printf("%d",arr[?]); return 0; }
The question is to replace "?" with an integer, so the output is 4. I'm not sure, but I don't think this is solvable in the standard way ?! (Do not call Undefined Behavior or depending on implementation) If not, then I am very interested to know how?
Change This problem is taken from here , I tried to solve with 10, but, unfortunately, this does not answer the question that asks the problem. However, I decided using some preliminary checks, depending on mumbo-jumbo, but I really have no explanation how this works!
Here is the answer: SPOILER , you can explain it
c ++ c puzzle
Quixotic
source share