Can anyone explain this code why it returning 8 | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 5

Can anyone explain this code why it returning 8

#include <stdio.h> int foo(int a[100]){ return sizeof(a); } int main() { int a[10]; printf("%d", foo(a)); return 0; }

21st Oct 2019, 9:27 AM
Preity
Preity - avatar
2 Answers
0
~ swim ~ , Hatsy Rei anyone can explain this
21st Oct 2019, 9:29 AM
Preity
Preity - avatar
0
~ swim ~ can you elaborate on that more please
21st Oct 2019, 9:47 AM
Rachit Sharma