Submission #19542838


Source Code Expand

Copy
#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); i++)
using namespace std;

int main() {
	int n; cin >> n;
	string s[n];
	for (auto &x : s) cin >> x;
	string res = s[0]+s[1];
	REP(i, n) REP(j, n)
		if (i != j)
			res = min(res, s[i]+s[j]);
	cout << res << '\n';
	return 0;
}

Submission Info

Submission Time
Task B - パスワード
User solareenlo
Language C++ (GCC 9.2.1)
Score 100
Code Size 307 Byte
Status AC
Exec Time 6 ms
Memory 3612 KB

Judge Result

Set Name All
Score / Max Score 100 / 100
Status
AC × 24
Set Name Test Cases
All input_0.txt, input_1.txt, input_10.txt, input_11.txt, input_12.txt, input_13.txt, input_14.txt, input_15.txt, input_16.txt, input_17.txt, input_18.txt, input_19.txt, input_2.txt, input_20.txt, input_21.txt, input_22.txt, input_23.txt, input_3.txt, input_4.txt, input_5.txt, input_6.txt, input_7.txt, input_8.txt, input_9.txt
Case Name Status Exec Time Memory
input_0.txt AC 6 ms 3468 KB
input_1.txt AC 2 ms 3520 KB
input_10.txt AC 2 ms 3472 KB
input_11.txt AC 2 ms 3536 KB
input_12.txt AC 2 ms 3528 KB
input_13.txt AC 2 ms 3520 KB
input_14.txt AC 2 ms 3468 KB
input_15.txt AC 2 ms 3568 KB
input_16.txt AC 2 ms 3476 KB
input_17.txt AC 2 ms 3536 KB
input_18.txt AC 2 ms 3612 KB
input_19.txt AC 2 ms 3468 KB
input_2.txt AC 2 ms 3532 KB
input_20.txt AC 3 ms 3580 KB
input_21.txt AC 2 ms 3520 KB
input_22.txt AC 2 ms 3532 KB
input_23.txt AC 2 ms 3560 KB
input_3.txt AC 2 ms 3588 KB
input_4.txt AC 2 ms 3568 KB
input_5.txt AC 2 ms 3496 KB
input_6.txt AC 2 ms 3532 KB
input_7.txt AC 2 ms 3468 KB
input_8.txt AC 2 ms 3468 KB
input_9.txt AC 2 ms 3584 KB