netjunky

Untitled

Feb 17th, 2011
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.45 KB | None | 0 0
  1. // Example
  2. //libs..
  3.  
  4. void example( int *forTest )
  5.  
  6. void example1( int forTest )
  7.  
  8. int main( int argc, char **argv )
  9. {
  10.     int a = 5;
  11.    
  12.     example( &a );
  13.     printf( "After test: %d", a );
  14.    
  15.     a = 5;
  16.    
  17.     example1( a );
  18.     printf( "After test: %d", a );
  19.  
  20.     return 0;
  21. }
  22.  
  23. void example( int *forTest )
  24. {
  25.     printf( "Before test: %d", forTest );
  26.    
  27.     forTest = 6;
  28. }
  29.  
  30. void example1( int forTest )
  31. {
  32.     printf( "Before test: %d", forTest );
  33.    
  34.     forTest = 6;
  35. }
Add Comment
Please, Sign In to add comment