fork(2) download
  1. #include <stdio.h>
  2.  
  3. int a,b,c = 0;
  4. void prtFun(void);
  5. int main(void)
  6. {
  7. static int a = 1; /* Line 1 */
  8. prtFun();
  9. a += 1;
  10. prtFun();
  11. printf("\n%d%d",a,b);
  12. }
  13.  
  14. void prtFun(void)
  15. {
  16. static int a = 2; /* Line 2 */
  17. int b=1;
  18. a += ++b;
  19. printf("\n%d%d",a,b);
  20. }
Success #stdin #stdout 0s 9432KB
stdin
Standard input is empty
stdout
42
62
20