fork(1) download
  1. #include <stdio.h>
  2.  
  3. int main() {
  4. char arquivo[] = "1 2 3 4 5";
  5. int a, b, c, d, e;
  6. sscanf (arquivo, "%d %d %d %d %d", &a, &b, &c, &d, &e);
  7. printf ("%d - %d - %d - %d - %d", a, b, c, d, e);
  8. }
  9.  
  10. //https://pt.stackoverflow.com/q/126395/101
Success #stdin #stdout 0s 4196KB
stdin
1
2
3
4
5
stdout
1 - 2 - 3 - 4 - 5