Advertisement
dllbridge

Untitled

Feb 8th, 2023
1,067
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.71 KB | None | 0 0
  1.  
  2. #include   <stdio.h>
  3.  
  4.  
  5.  
  6.  
  7. int n = 77;
  8.  
  9. int *p = &n;
  10.  
  11.  
  12.  
  13. /////////////////////////////////////////////////
  14. int main()                                     //
  15. {
  16.    
  17.     printf(" p = %7d\n",  p);
  18.     printf("*p = %7d\n", *p);  
  19.     printf(" n = %7d\n",  n);
  20.     printf("&n = %7d\n", &n);      
  21. }
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55. /*
  56. #include   <stdio.h>
  57.  
  58.  
  59.  
  60.  
  61. void foo(int *);
  62.  
  63.  
  64.  
  65. /////////////////////////////////////////////////
  66. int main()                                     //
  67. {
  68.     int nSec = 0;
  69.    
  70.     foo(&nSec);
  71.    
  72.     printf("nSec = %d", nSec);
  73.  
  74. return 0;
  75. }
  76.  
  77.  
  78.  
  79.  
  80. //////////////////////////////////////////////////
  81. void foo(int *s)
  82. {
  83.    
  84.  
  85.  
  86.     (*s)++;
  87. }
  88.  
  89. */
  90.  
  91.  
  92.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement