結果
| 問題 |
No.113 宝探し
|
| コンテスト | |
| ユーザー |
nak2yoshi
|
| 提出日時 | 2016-02-19 22:45:30 |
| 言語 | D (dmd 2.109.1) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 5,000 ms |
| コード長 | 298 bytes |
| コンパイル時間 | 2,588 ms |
| コンパイル使用メモリ | 147,456 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-12 02:57:24 |
| 合計ジャッジ時間 | 3,573 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 23 |
ソースコード
import std.stdio,
std.conv,
std.string,
std.range,
std.math,
std.algorithm;
void main()
{
auto S = readln.strip;
auto x = S.count!"a=='E'" - S.count!"a=='W'";
auto y = S.count!"a=='N'" - S.count!"a=='S'";
(x * x + y * y).to!real.sqrt.writeln;
}
nak2yoshi