Merge "Switch from `count` to `N` for template due to ambiguity with `std::count`"