#include "stdio.h" int main(void){ double i; while(scanf("%lf", &i) != EOF){ if(i < 0){ i = -i; printf("%.2lf\n", i); } else{ printf("%.2lf\n", i); } } return 0; }
时间: 2024-11-09 04:01:30
#include "stdio.h" int main(void){ double i; while(scanf("%lf", &i) != EOF){ if(i < 0){ i = -i; printf("%.2lf\n", i); } else{ printf("%.2lf\n", i); } } return 0; }