PAT 1037 Magic Coupon (25分) 贪心+排序+负负/正正得正
PAT 1037 Magic Coupon (25分) 贪心+排序+负负/正正得正
|
The magic shop in Mars is offering some magic coupons. Each coupon has an integer N printed on it, meaning that when you use this coupon with a product, you may get N times the value of that product back!
PAT 1033 To Fill or Not to Fill (25分) 贪心思想
PAT 1033 To Fill or Not to Fill (25分) 贪心思想
|
With highways available, driving a car from Hangzhou to any other city is easy. But since the tank capacity of a car is limited, we have to find gas stations on the way from time to time.