摘要: 1 //occupyed_1检查行是否占用 2 //occupyed_2检查列是否占用 3 //occupyed_3检查块是否占用 4 bool isValidSudoku(vector>& board) 5 { 6 int occupyed_1[9][9], occupyed_2[9][... 阅读全文
posted @ 2015-07-08 21:33 QingLiXueShi 阅读(156) 评论(0) 推荐(0) 编辑
摘要: 1 enum status{VALID = 0, INVALID}; 2 int g_status; 3 4 long long SubStrToInt(const char* str, bool minus) 5 { 6 long long num = 0; 7 int fl... 阅读全文
posted @ 2015-07-08 16:48 QingLiXueShi 阅读(186) 评论(0) 推荐(0) 编辑
摘要: 1 class Queue { 2 public: 3 // Push element x to the back of queue. 4 void push(int x) { 5 while (!nums.empty()) { 6 nums... 阅读全文
posted @ 2015-07-08 14:38 QingLiXueShi 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 1 class Stack { 2 public: 3 // Push element x onto stack. 4 void push(int x) { 5 int len = nums.size(); 6 nums.push(x); 7 ... 阅读全文
posted @ 2015-07-08 11:29 QingLiXueShi 阅读(133) 评论(0) 推荐(0) 编辑