最新华为OD机试
题目描述: 组成最大数
小组中每位都有一张卡片,卡片上是6位内的正整数,将卡片连起来可以组成多种数字,计算组成的最大数字。
输入描述
“,”号分割的多个正整数字符串,不需要考虑非数字异常情况,小组最多25个人。
输出描述
最大的数字字符串
用例1
输入
22,221
输出
22221
用例2
输入
4589,101,41425,9999
输出
9999458941425101
C++
#include <iostream>
#include <algorithm>
#include <vector>
using namespace std;
int main() {
string input;

订阅专栏 解锁全文
7322

被折叠的 条评论
为什么被折叠?



