Search found 4 matches

by zslwyuan
Tue Aug 09, 2011 5:21 am
Forum: Volume 102 (10200-10299)
Topic: 10278 - Fire Station
Replies: 59
Views: 20422

I Ac All the Samples that you gave, But WA,WHY!!HELP!!!

#include<cstdio> #include<cstring> using namespace std; int map[501][501],zj[501],yl[102],now[501]; bool used[501]; int main() { // freopen("1.txt","r",stdin); // freopen("2.txt","w",stdout); int i,j,k,l,n,m,t,o=0;scanf("%d\n",&t); while (t--) { if (o)printf("\n");o=1; scanf("%d %d",&m,&n); memset(u...
by zslwyuan
Thu Jan 27, 2011 4:45 am
Forum: Volume 105 (10500-10599)
Topic: 10599 - Robots(II)
Replies: 27
Views: 9963

Can anyone find a case for me?

Can anyone find a case for me? I have tried many case,and haven't found it get wrong. But I WA? why? My Code: #include<cstdio> #include<cstring> using namespace std; int map[102][102],dp[102][102],prh[10001],n,m,hmn; long long tp[10001][3],tpf[10001],check[10001],dhm[102],dsm[102],ans; void prhelp(i...
by zslwyuan
Tue Jan 25, 2011 4:01 am
Forum: Volume 106 (10600-10699)
Topic: 10626 - Buying Coke
Replies: 23
Views: 15718

10626 I can't find anything wrong but……

I can't find anything wrong but failed this case: 1 150 500 100 20 My Code: #include<cstdio> #include<cstring> #include<cstdlib> using namespace std; int dpp[151][101][51],used[151][101][51],cct,t,C,N1,N5,N10,M; int dp(int c,int n5,int n10) { int n1=M-(C-c)*8-n5*5-n10*10; if (n1<0||n5<0||n10<0) retu...
by zslwyuan
Sun Nov 28, 2010 10:13 am
Forum: Volume 105 (10500-10599)
Topic: 10564 - Paths through the Hourglass
Replies: 30
Views: 13226

Re: 10564 - Paths through the Hourglass

I have gotten Wrong, However , I can't find the mistake, Please help me Check The Code? My Idea: First I use the DP to get the sum of the paths, Then, I use the DFS to find out the best path. ==========================================>>I got Wrong Answer Help! #include<cstdio> #include<cstring> #inc...

Go to advanced search