fork download
  1. #include <stdio.h>
  2. #include <math.h>
  3.  
  4. int main(void)
  5. {
  6. int y;
  7. double x;
  8.  
  9. puts(" 0.000 0.200 0.400 0.600 0.800");
  10. for(y=0;y<=4;y++) {
  11. printf("%d", y);
  12. for(x=0;x<=0.8;x+=0.2) {
  13. printf(" %.3f", sqrt(x + y));
  14. }
  15. puts("");
  16. }
  17.  
  18. return 0;
  19. }
  20.  
Success #stdin #stdout 0s 2248KB
stdin
Standard input is empty
stdout
  0.000 0.200 0.400 0.600 0.800
0 0.000 0.447 0.632 0.775 0.894
1 1.000 1.095 1.183 1.265 1.342
2 1.414 1.483 1.549 1.612 1.673
3 1.732 1.789 1.844 1.897 1.949
4 2.000 2.049 2.098 2.145 2.191