結果
| 問題 |
No.83 最大マッチング
|
| コンテスト | |
| ユーザー |
spacia
|
| 提出日時 | 2015-12-19 12:40:46 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 517 bytes |
| コンパイル時間 | 2,545 ms |
| コンパイル使用メモリ | 75,404 KB |
| 実行使用メモリ | 54,548 KB |
| 最終ジャッジ日時 | 2024-09-16 08:55:04 |
| 合計ジャッジ時間 | 3,754 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 2 WA * 8 |
ソースコード
import java.io.*;
import java.util.*;
class Main155 {
public static void main (String[] args) throws IOException {
BufferedReader br =
new BufferedReader(new InputStreamReader(System.in));
int n = Integer.parseInt(br.readLine());
int cnt = 0;
String add = "", ans = "";
if (n % 3 == 0)
cnt = n / 3;
else if (n % 3 == 1) {
cnt = (n - 4) / 3;
add = "11";
} else {
cnt = n / 3;
add = "1";
}
for (int i = 0; i < cnt; i++)
ans += "7";
System.out.println(ans + add);
}
}
spacia