Check the Check Problem (UVA 10196)