結果

問題 No.597 concat
ユーザー Project2017C2
提出日時 2017-12-11 14:10:01
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 572 bytes
コンパイル時間 1,749 ms
コンパイル使用メモリ 167,312 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-11-30 11:38:26
合計ジャッジ時間 2,084 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 11
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.cpp: In function 'll gcd(ll, ll)':
main.cpp:16:17: warning: control reaches end of non-void function [-Wreturn-type]
   16 |         else gcd(b, a%b);
      |              ~~~^~~~~~~~

ソースコード

diff #

#include "bits/stdc++.h"

using namespace std;
using ll = long long;
using IP = pair<int, int>;

const ll INF = 1LL << 62;
#define atcoder(int)1e9+7
#define Endl endl
#define mp make_pair
#define all(v) v.begin(),v.end()
#define pb push_back

ll gcd(ll a, ll b) {//最大公約数
	if (a%b == 0)return b;
	else gcd(b, a%b);
}

ll lcm(ll a, ll b) {//最小公倍数
	return (a / gcd(a, b))*b;
}

int main(){

	int n;
	string s[20];

	cin >> n;

	for (int i = 0; i < n; i++) {
		cin >> s[i];
	}

	for (int i = 0; i < n; i++) {
		cout << s[i];
	}
	cout << endl;

	return 0;
}
0