Greedy Algorithm: Minimum Plank Coverage for Barn Stalls
1349. Barn Repair - AcWing
Difficulty: Medium
Time/Memory Limit: 1s / 64MB
Total Accepted: 1275
Total Submissions: 2405
Source: usaco training 1.4
Algorithm: Greedy
Problem Description
During a stormy night, strong winds damaged the roof and doors of Farmer John's barn. The stalls are arranged in a single row, and cows occup ...
Posted on Wed, 07 Oct 2026 16:12:07 +0000 by chris9902
Core Algorithmic Techniques in Java for Competitive Programming
Sorting, searching, dynamic programing, and graph algorithms form the backbone of competitive programming. This article presents a curated list of such patterns, each accompanied by a concise Java implementation. The examples draw inspiration from the ACwing problem set, covering topics from basic sorting to advanced combinatorial mathematics.
...
Posted on Mon, 15 Jun 2026 17:07:00 +0000 by zhaohongli