fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int hankei;
  5. double S,L;
  6. scanf("%d", &hankei);
  7. S=3.14*hankei*hankei;
  8. L=hankei*2*3.14;
  9. printf("%.5f\n", S);
  10. printf("%.3f\n", L);
  11. return 0;
  12. }
  13.  
Success #stdin #stdout 0.01s 5288KB
stdin
7
stdout
153.86000
43.960