fork(1) download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int n = 123;
  5.  
  6. printf("%d\t %d\n", n); //%d: 123
  7. printf("%.5d\t %.5d\n", n); //%.5d 00123
  8. printf("%.2d\t %.2d\n", n); //%.2d 123
  9. return 0;
  10. }
  11.  
Success #stdin #stdout 0s 5288KB
stdin
Standard input is empty
stdout
123	 -1160416864
00123	 00000
123	 00