/* segFault1.c  P. Conrad 9/16/05

This file should make a segmentation fault
becuase we do a scanf without the & 

*/

#include <stdio.h>

int main(void)
{
  int x; /* this is a declaration for the variable x */

  x = 1; /* this is an assignment statment */

  /* since that was the "first" assignment to x, it
     might be consider the "initial" assignment to x,
     therefore it is sometimes called the "Initialization" */


  printf("enter value for x:");
  scanf("%d",&x);  /* should be &x */

  printf("x=%d\n",x);

  return 0;

}









