Submission #3767826
Source Code Expand
import std.algorithm; import std.array; import std.conv; import std.math; import std.range; import std.stdio; import std.string; import std.typecons; T read(T)() { return readln.chomp.to!T; } T[] reads(T)() { return readln.split.to!(T[]); } alias readint = read!int; alias readints = reads!int; bool isMatch(string s) { switch (s) { case "TAKAHASHIKUN": case "Takahashikun": case "takahashikun": return true; default: return false; } } void main() { readint; auto ss = reads!string; ss[$-1] = ss[$-1].stripRight("."); auto ans = ss.filter!(isMatch).count; writeln(ans); }
Submission Info
Submission Time | |
---|---|
Task | A - 大好き高橋君 |
User | noriok |
Language | D (DMD64 v2.070.1) |
Score | 0 |
Code Size | 669 Byte |
Status | CE |
Compile Error
./Main.d(29): Error: no overload matches for stripRight(Range, E)(Range range, E element) if (isBidirectionalRange!Range && is(typeof(range.back == element) : bool))