Advertisement
Guest User

Untitled

a guest
Aug 27th, 2011
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. #include <string.h>
  2. #include <stdio.h>
  3.  
  4. void my_func(char buf[25])
  5. {
  6. printf("Sizeof(1): %d\n", sizeof(buf));
  7. }
  8.  
  9. void my_func2(char *buf)
  10. {
  11. printf("Sizeof(2): %d\n", sizeof(buf));
  12. }
  13.  
  14.  
  15. int main(void)
  16. {
  17. char buf[25];
  18. my_func(buf);
  19. my_func2(buf);
  20. return 0;
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement