title: Function to increment the value of a variable in C
body: <p>I wrote the same code in PHP, the value of 5 got incremented, but
  why doesn't the value get incremented in C?</p>
  
  <pre><code>int foo(int x){
     x++;
  }
  
  int main( ){
     int y = 5;
     foo(y);  
     printf("value of y = %d\n", y);
  }
  </code></pre>