SHARE
TWEET

Read Until 'n'

a guest Oct 13th, 2017 55 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. char c;
  2. int i, dat[100];
  3.  
  4. i = 1;
  5.  
  6. scanf("%d", &dat[0]);
  7.  
  8. while ( (c = getchar()) != '\n' )
  9. {
  10.     scanf("%d%c", &dat[i], &c);
  11.     i++;
  12. }
RAW Paste Data
Top