結果
| 問題 |
No.542 1円玉と5円玉
|
| コンテスト | |
| ユーザー |
mori_chibi
|
| 提出日時 | 2017-08-17 17:07:27 |
| 言語 | C#(csc) (csc 3.9.0) |
| 結果 |
AC
|
| 実行時間 | 26 ms / 2,000 ms |
| コード長 | 765 bytes |
| コンパイル時間 | 2,116 ms |
| コンパイル使用メモリ | 103,168 KB |
| 実行使用メモリ | 17,920 KB |
| 最終ジャッジ日時 | 2024-10-14 13:51:51 |
| 合計ジャッジ時間 | 1,860 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 10 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace OneAndFive
{
class Program
{
static void Main(string[] args)
{
int[] r = new int[601];
string[] s = Console.ReadLine().Split(' ');
var a = int.Parse(s[0]);
var b = int.Parse(s[1]);
for (int i = 0; i <= a; i++)
{
for (int j = 0; j <= b; j++)
{
r[i + j * 5] = 1;
}
}
for (int x = 1; x < 601; x++)
{
if(r[x] == 1)
{
Console.WriteLine(x);
}
}
}
}
}
mori_chibi