USACO 3.4 American Heritage | heritage | c++

Different order of Binary tree: Recursion
Read Source Code

Advertisements
Posted in USACO Training | Tagged | Leave a comment

USACO 3.4 Electric Fence | fence9 | c++

Pick’s theorem
Read Source Code

Posted in USACO Training | Tagged | 3 Comments

USACO 3.3 Camelot | camelot | c++

Breadth First + Brute Force Search.
Read Source Code

Posted in USACO Training | Tagged | 4 Comments

USACO 3.3 Riding The Fences | fence | c++

Eulerian Tours
Read Source Code

Posted in USACO Training | Tagged | Leave a comment

USACO 3.3 Home on the Range | range | c++

Find all [all-1 square] in a matrix.
Classic Dynamic Programming.
range.cpp
Read Source Code

Posted in USACO Training | Tagged | Leave a comment

USACO 3.3 Shopping Offers | shopping | c++

5-dimensional dynamic programming.
Sounds hard, but actually it’s not.

Read Source Code

Posted in USACO Training | Tagged | Leave a comment

USACO 3.3 A game | game1 | c++

DP
Read Source Code

Posted in USACO Training | Tagged | Leave a comment