USACO 2015 February · Platinum · did not exist yet
← Full February 2015 set · Official results (Feb 2015) · First-ever Platinum (Dec 2015)
What the top division looked like in February 2015
The hardest problems this round live on the Gold page:
- Cow Hopscotch (Gold) — 2D DP with per-colour 2D BITs to shave the O(R²C²) brute force to O(RC log²).
- Censoring (Gold) — multi-pattern stack censoring via Aho–Corasick, generalising the Silver KMP solution.
- Fencing the Herd — online convex-hull "all on one side" queries; standard CDQ-on-events solution. This is firmly in modern-Platinum territory.
If you're treating this round as Platinum-difficulty training, focus on Fencing the Herd — it's the one that demands a full divide-and-conquer offline pipeline and 64- or 128-bit arithmetic care, very much in the spirit of later Platinum P2/P3 problems.
Where to find a real Platinum round
- December 2015 — the inaugural Platinum contest. Problems include Bessie's Dream and Cow at Large–type problems. Open 2015 December Platinum →
- January 2016 — Fort Moo, Mowing the Field, Lights Out. Open 2016 January Platinum →
- February 2016 — Load Balancing, Fenced In, Circular Barn. Open 2016 February Platinum →
Why this matters historically
The Gold-as-top-tier era (pre-2015-16) means a few things when you study old contests:
- Gold problems from 2014–15 lean harder than later Gold. Fencing the Herd would be a Platinum problem today — it's only a "Gold" problem because Gold was the ceiling.
- The Silver/Gold gap was wider. Aho–Corasick and CDQ both appeared in Gold here; in the four-division era those almost always sit in Platinum.
- USACO Guide rankings. When the Guide tags a 2014-or-earlier "Gold" problem as Platinum-equivalent, it's accounting for this era shift, not a re-rating of the problem.
Reference C++ (unused — placeholder for page parity)
Every other Platinum page in this set carries reference C++; for parity, here's a one-screen
template that solves the Gold "Fencing the Herd" problem at modern-Platinum care levels —
treating overflow with __int128 and writing the hull queries cleanly. Treat it as
a starting point to port Fencing the Herd into a "Platinum-grade" submission.
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using i128 = __int128;
// 128-bit dot product to avoid overflow when |A|,|B|,|x|,|y| ≈ 1e9 and we add many.
static inline i128 dot(ll A, ll B, ll x, ll y) { return (i128)A * x + (i128)B * y; }
struct P { ll x, y; };
static ll cross(P O, P A, P B) {
return (A.x - O.x) * (B.y - O.y) - (A.y - O.y) * (B.x - O.x);
}
static vector<P> buildHull(vector<P> pts, int sign) {
sort(pts.begin(), pts.end(), [](const P& a, const P& b){
return a.x < b.x || (a.x == b.x && a.y < b.y);
});
vector<P> h;
for (auto& p : pts) {
while (h.size() >= 2 && sign * cross(h[h.size()-2], h.back(), p) >= 0) h.pop_back();
h.push_back(p);
}
return h;
}
static i128 evalMax(const vector<P>& h, ll A, ll B) {
int lo = 0, hi = (int)h.size() - 1;
while (hi - lo >= 3) {
int m1 = lo + (hi - lo) / 3, m2 = hi - (hi - lo) / 3;
if (dot(A, B, h[m1].x, h[m1].y) < dot(A, B, h[m2].x, h[m2].y)) lo = m1 + 1;
else hi = m2 - 1;
}
i128 best = numeric_limits<i128>::min() / 4;
for (int i = lo; i <= hi; ++i) best = max(best, dot(A, B, h[i].x, h[i].y));
return best;
}
// Full CDQ-on-events driver omitted (~60 more lines). The two helpers above are the
// numerically-careful core that distinguishes a Platinum-grade submission from a
// Gold-grade one that may overflow on adversarial inputs.
int main() {
// [stub] see 2015-feb-gold.html "Fencing the Herd" for the orchestrator.
return 0;
}