文章

2

粉丝

0

获赞

0

访问

220

头像
字符移动 题解:
P1012 贵州大学机试题
发布于2026年1月16日 19:32
阅读数 86

#include<iostream>
#include<string>
int main(){
    std::string str,front,back;
    std::cin>> str;
    
    for(auto c:str){
        if('0'<=c && c<='9'){
            back+=c;    
        }else{
            front+=c;
        }
    }
    std::cout<<front+back;
}

登录查看完整内容


登录后发布评论

暂无评论,来抢沙发