結果
| 問題 | No.29 パワーアップ |
| コンテスト | |
| ユーザー |
pirorirori_n712
|
| 提出日時 | 2018-07-28 12:03:02 |
| 言語 | C#(csc) (csc 3.9.0) |
| 結果 |
AC
|
| 実行時間 | 18 ms / 5,000 ms |
| + 939µs | |
| コード長 | 718 bytes |
| 記録 | |
| コンパイル時間 | 465 ms |
| コンパイル使用メモリ | 104,704 KB |
| 実行使用メモリ | 19,712 KB |
| 最終ジャッジ日時 | 2026-07-15 22:06:46 |
| 合計ジャッジ時間 | 2,177 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 22 |
コンパイルメッセージ
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;
class No29{
static void Main(){
var a=Int32.Parse(Console.ReadLine());
List<string> list=new List<string>();
for(int i=0;i<a;++i){
var b=Console.ReadLine().Split(' ');
list.Add(b[0]);
list.Add(b[1]);
list.Add(b[2]);
}
list.Sort();
var c=list.Count;
var d=0;
var e=0;
for(int i=0;i<c-1;++i){
if(list[i]==list[i+1]){
d++;
if(i==c-3)e++;
i++;
}else{
e++;
if(i==c-2)e++;
}
}
Console.WriteLine(d+e/4);
}
}
pirorirori_n712