标签:
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2897
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 3320 Accepted Submission(s): 1499
1 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 #include <iostream> 32 #include <cstdio> 33 #include <cstring> 34 #include <stack> 35 #include <queue> 36 #include <map> 37 #include <set> 38 #include <vector> 39 #include <cmath> 40 #include <algorithm> 41 using namespace std; 42 #define ll long long 43 const double eps = 1e-6; 44 const double pi = acos(-1.0); 45 const int INF = 0x3f3f3f3f; 46 const int MOD = 1000000007; 47 48 int main () 49 { 50 int n,p,q; 51 while (scanf ("%d%d%d",&n,&p,&q)==3) 52 { 53 int s = n%(p+q); 54 if (s>0 && s<=p) 55 printf ("LOST\n"); 56 else 57 printf ("WIN\n"); 58 } 59 return 0; 60 }
标签:
原文地址:http://www.cnblogs.com/dxd-success/p/4707419.html