My Solutions to UVA online judge problems