F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_29276835_5337.cpp:1:9: error: #include expects "FILENAME" or <FILENAME>
 #include#includeusing namespace std;//012345678901234char translate[16] = "3456789TJQKA2BR";char tot[16] = "444444444444411";int a[3][16];int b[15];int limit[5] = {0, 5, 3, 0, 0};int big[5][16];//a[i][j] ¡À¨ªÊ¾Ï¨¤Í¬¡ÁÖĸÊýÁ¿Îªi?¬Á¬ÅÆÕÅÊýΪjµÄ¡Áî´¨®µÄÆðʼλÖà bool rocket;int attach[16][3];//attach[i][j] ¡À¨ªÊ¾Á¬Ðøi¸öÈýÕÅÅÆ?¬´øjÕÅÅƵġÁî´¨®ÆðʼλÖà int get(char c){ for (int i = 0; i < 15; ++i) if (translate[i] == c) return i;} void init(int i, string s){ memset(a[i], 0, sizeof(a[i])); for (int j = 0; j < s.size(); ++j) ++a[i][get(s[j])];}void init(int index){ if (!index){ memset(big, 255, sizeof(big)); memset(attach, 255, sizeof(attach)); rocket = false; return; } if (a[index][14]&&a[index][13]) rocket = true; int b[3] = {0, 0, 0}; for (int i = 0; i < 15; ++i) for (int k = 1; k < 3; ++k) if (a[index][i] >= k) ++b[k]; //cout< 1)&&(i + len > 12)) break; int ok = true; if (a[index][i + len - 1] >= cardnumber){ big[cardnumber][len] = max(big[cardnumber][len], i); if ((cardnumber == 3)&&(b[1] >= 2 * len)) attach[len][1] = max(attach[len][1], i); if ((cardnumber == 3)&&(b[2] >= 2 * len)) attach[len][2] = max(attach[len][2], i); } else break; //cout<<"___"<= 2)&&(b[len - 1] + b[len - 2] == 27)) return false; return dfs(remain - (3 + cardnumber) * len, 4000 + i + len, fail); } for (int j = begin; j < 15; ++j){ if (j == i) j = i + len; //cout<= cardnumber){ a[0][j] -= cardnumber; b[index] = j; if (dfs(cardnumber, remain, i, len, index + 1, j + 1,fail)) return true; a[0][j] += cardnumber; } } return false;}bool dfs(int remain, int level, bool fail){ /* int tot = 0; cout< -1)&&(fail)) return false; //cout<= p) for (int k = j + 1; k < 15; ++k) if (a[0][k] >= p){ a[0][j] -= p; a[0][k] -= p; if (dfs(remain - 2 * p - 4, 2000 + i + 1, fail|(big[4][1] >= 0))) return true; a[0][k] += p; a[0][j] += p; } a[0][i] += 4; } return dfs(remain, 3000, fail); } //cout< 1)&&(i + len > 12)))&&(a[0][i + len - 1] >= cardnumber)){ //cout< i))||(!fail))&&((len >= limit[cardnumber])||(len == 1))) if (dfs(remain - cardnumber * len, 3000 + i, fail||(big[cardnumber][len] > i))) return true; }else{ for (int j = 0; j < len - 1; ++j) a[0][i + j] += cardnumber; break; } } return dfs(remain, 4000, fail); } //attach for (int i = level % 1000; i < 15; ++i) for (int cardnumber = 1; cardnumber < 3; ++cardnumber) for (int len = 1; len + i <= 16; ++len){ if ((!((len > 1)&&(i + len > 12)))&&(a[0][i + len - 1] >= 3)){ a[0][i + len - 1] -= 3; if ((!(attach[len][cardnumber] > i))||(!fail)){ if (dfs(cardnumber, remain, i, len, 0, 0, (attach[len][cardnumber] > i)||fail)) return true; } }else{ for (int j = 0; j < len - 1; ++j) a[0][i + j] += 3; break; } } return false;}int main(){ /* freopen("in.txt", "r", stdin); freopen("out.txt", "w", stdout); */ int t, _t; for (scanf("%d ", &_t), t = 0; t < _t; ++t){ for (int i = 0; i < 3; ++i){ string s; cin>>s; //cout<= 0){ for( int i = 1; i <= 3; ++i) for (int j = 1; j < 16; ++j) big[i][j] = 100; for (int i = 1; i <= 2; ++i) for (int j = 0; j < 16; ++j) attach[j][i] = 100; } /* for (int i = 1; i <= 4; ++i) for (int j = 1; j <=15; ++j) cout< 
         ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-25 19:25:15, Gzip enabled