20分求助
查看原帖
20分求助
1144722
zhy15353494080楼主2024/4/3 21:09
#include<bits/stdc++.h>

using namespace std;

int main(){

	double x;
    
	cin>>x;
    
	if(x>=0){
		cout<<fixed<<setprecision(2)<<x;
        
	}
	else if(x<0){
    
		int i=(-1)*x;
		cout<<fixed<<setprecision(2)<<i;
        
	}
    
	return 0;
    
}
2024/4/3 21:09
加载中...