|
杨坤霖 (steven)
|
4ms |
7 MiB |
|
326 Bytes |
2023-12-3 14:10:56 |
|
许律天
|
6ms |
7.2 MiB |
|
318 Bytes |
2023-12-14 21:02:19 |
|
黄相茗
|
7ms |
264 KiB |
|
359 Bytes |
2022-4-7 19:25:39 |
|
赵泳鑫 (zhaoyongxin)
|
7ms |
384 KiB |
|
359 Bytes |
2022-4-16 19:57:58 |
|
疯神芭芭脱丝 (李卓修)
|
7ms |
312 KiB |
|
341 Bytes |
2022-6-12 17:55:49 |
|
龙湖时代C馆-邹镇宇 (邹镇宇)
|
8ms |
7 MiB |
|
294 Bytes |
2023-12-3 14:11:14 |
|
(张洛诚)
|
12ms |
384 KiB |
|
427 Bytes |
2023-4-29 20:04:31 |
|
ycy
|
13ms |
392 KiB |
|
379 Bytes |
2022-6-29 19:44:35 |
|
张泰凌 (ztl)
|
13ms |
384 KiB |
|
329 Bytes |
2022-6-3 20:32:31 |
|
1396013295
|
13ms |
436 KiB |
|
516 Bytes |
2022-3-27 9:06:02 |
|
陈杰晟
|
13ms |
440 KiB |
|
334 Bytes |
2022-5-29 16:02:18 |
|
zcszcs
|
13ms |
7.1 MiB |
|
250 Bytes |
2023-9-23 17:35:07 |
|
在煎鱼的肖大总铳 (肖宇航)
|
13ms |
6.8 MiB |
|
298 Bytes |
2023-10-12 22:13:05 |
|
重庆龙湖源著校区+杨聆暄 (杨聆暄)
|
13ms |
384 KiB |
|
449 Bytes |
2023-1-28 16:16:17 |
|
hzm
|
13ms |
384 KiB |
|
285 Bytes |
2022-9-13 21:49:09 |
|
ywh
|
14ms |
512 KiB |
|
292 Bytes |
2022-6-3 20:29:51 |
|
文硕 (文硕1)
|
14ms |
448 KiB |
|
313 Bytes |
2023-2-2 14:43:31 |
|
Aphrode
|
14ms |
6.7 MiB |
|
692 Bytes |
2023-9-1 12:01:01 |
|
姚宏逸
|
14ms |
6.7 MiB |
|
251 Bytes |
2023-8-24 18:03:19 |
|
AC[谭赫奕] (tanheyi)
|
14ms |
6.8 MiB |
|
318 Bytes |
2023-9-9 11:20:16 |
|
龙思颖 (lsy)
|
14ms |
6.9 MiB |
|
319 Bytes |
2023-9-9 11:26:05 |
|
zzy
|
14ms |
384 KiB |
|
298 Bytes |
2023-3-18 15:23:42 |
|
爱琴海校区-刁钲洋 (刁钲洋)
|
14ms |
6.9 MiB |
|
427 Bytes |
2023-7-4 12:00:55 |
|
时代1校-杨宇轩 (杨宇轩)
|
14ms |
6.8 MiB |
|
300 Bytes |
2023-9-9 11:22:12 |
|
小翔的粉丝
|
14ms |
6.8 MiB |
|
315 Bytes |
2023-9-9 11:21:22 |
|
张梓浩 (zhangzihao)
|
14ms |
6.7 MiB |
|
319 Bytes |
2023-9-20 20:37:53 |
|
小忙果 (王昱杰)
|
14ms |
7.6 MiB |
|
335 Bytes |
2023-7-18 9:32:04 |
|
没有此人 (akm)
|
14ms |
6.7 MiB |
|
353 Bytes |
2023-10-1 11:44:43 |
|
城市之光1
|
15ms |
6.8 MiB |
|
316 Bytes |
2023-9-9 11:21:55 |
|
孙烽轶 (sfy)
|
15ms |
6.9 MiB |
|
323 Bytes |
2023-7-9 9:46:23 |
|
新壹街校区-陈琬舒 (空空大师)
|
15ms |
6.7 MiB |
|
303 Bytes |
2023-9-9 11:47:43 |
|
杜俊宏
|
15ms |
7.5 MiB |
|
269 Bytes |
2023-7-12 11:19:02 |
|
huanglu
|
15ms |
6.9 MiB |
|
351 Bytes |
2023-7-4 21:04:26 |
|
龙湖时代C馆-邹镇宇 (邹镇宇)
|
15ms |
6.9 MiB |
|
310 Bytes |
2023-7-18 13:39:16 |
|
李哲 (lizhe)
|
15ms |
392 KiB |
|
285 Bytes |
2022-9-13 21:49:51 |
|
新壹街校区-吴鑫鹏 (吴鑫鹏)
|
15ms |
392 KiB |
|
324 Bytes |
2023-3-18 15:25:00 |
|
金沙-文豪 (wenhao)
|
15ms |
6.7 MiB |
|
488 Bytes |
2023-9-18 22:00:25 |
|
maobohan
|
15ms |
6.8 MiB |
|
318 Bytes |
2023-9-9 11:21:25 |
|
祝熙承 (zxc)
|
15ms |
436 KiB |
|
349 Bytes |
2023-3-18 15:27:12 |
|
Aphrode
|
15ms |
6.7 MiB |
|
773 Bytes |
2023-9-1 11:59:10 |
|
什蒂尔布 (吴东航)
|
15ms |
512 KiB |
|
340 Bytes |
2023-3-18 15:25:03 |
|
colin1112 (墙凌可)
|
15ms |
444 KiB |
|
293 Bytes |
2023-3-18 14:57:32 |
|
龙思颖 (lsy)
|
15ms |
6.9 MiB |
|
319 Bytes |
2023-9-9 11:25:54 |
|
林昱霏
|
15ms |
6.9 MiB |
|
316 Bytes |
2023-9-9 11:25:27 |
|
scallway
|
15ms |
6.9 MiB |
|
256 Bytes |
2023-9-9 11:01:03 |
|
jighghjkfkhfdhdfdfdsfsdfsafvmnkbnkbmnlvnmkbvnvb;,.m;,;.;,;kbvlmkbnlmkblnvkmlbnkmlbvkmlbvklmbkmlkblmbnm;,l.,.;,'.,';.[',;.[,kjkoihgfhfgiohifgohifgohiofgihgofhiofgihofgihofgihofgiho;''[;.',m;.',m.;',.;'m,.;';'cv;x'cb'cx;b'cv;b'xc;b'c;b'cvbvc.'bv.//,/vb./vcb./cvbv,c.b,cv.,b.cv,b.vc,bg;hgl;hgl;hg;h;hfg;hl;lf;l;lxc;cln;bvln;vcln;vnl;vbl;vbln;vlv;blnvb;plnp;lplhfljpjh;nlvb;nv;bn;vcvl;nlv;nlv;g;hjhchl;ghfghl;fghl;ltlh;l;hlf;lg;bnlc;;nlv;nbv;nbv;nvb;nlvcnl;xc;blxcb;ll;hg;lhgl;dfl;t;ldy;l;lyl;rewlt493;l;dl;dsflg;lsdlpbpcxobpocvbpopopopreopotpreotertertretert (litingxu)
|
15ms |
6.9 MiB |
|
237 Bytes |
2023-7-15 8:20:20 |
|
时代一校-赵彦博 (zyb)
|
15ms |
6.9 MiB |
|
283 Bytes |
2023-7-15 11:12:17 |
|
徐正旺 (xzw)
|
15ms |
7.1 MiB |
|
386 Bytes |
2023-7-14 16:41:21 |
|
zzy
|
15ms |
512 KiB |
|
298 Bytes |
2023-3-18 15:23:39 |
|
林昱霏
|
15ms |
7 MiB |
|
316 Bytes |
2023-9-9 11:26:46 |
|
殷语函
|
15ms |
6.8 MiB |
|
318 Bytes |
2023-9-9 11:20:59 |
|
zhm123
|
15ms |
440 KiB |
|
295 Bytes |
2023-2-11 11:00:23 |
|
Chter
|
16ms |
6.8 MiB |
|
427 Bytes |
2023-7-4 0:48:05 |
|
三差学生(尘埃蓝莓) (白佳睿)
|
16ms |
7.1 MiB |
|
272 Bytes |
2023-9-9 11:27:36 |
|
手搓STL stack 双向无环链表 _ 向量 2种实现方式: template <typename Map_Type> class Stack_l /* Stack _ List */ { private: struct Node { Map_Type Node_Data; Node *nextp, *lastp; Node(void) { nextp = 0; lastp = 0; } }; struct List_Data { unsigned int List_Size; Node *headp, *endp; List_Data(void) { List_Size = 0; headp = 0; endp = 0; } }Data; struct Vector_Data { Map_Type *headp, *lastp, *endp; void resize(unsigned int data_size) { Map_Type *newp = new Map_Type[data_size](); endp = newp + data_size - 1; lastp = newp + (data_size > lastp - headp ? lastp - headp : data_size); if (headp) delete[] headp; headp = newp; } Vector_Data(void) { headp = 0; lastp = 0; endp = 0; } }; public: unsigned int size(void) { return Data.List_Size; } Map_Type& top(void) { return Data.endp -> Node_Data; } void* data(void) { return &Data; } bool empty(void) { return !((bool)Data.headp); } Stack_l<Map_Type>& push(Map_Type push_data) { Node *nodep = new Node(); nodep -> lastp = Data.endp; if (!Data.headp) { Data.headp = nodep; Data.endp = nodep; } else Data.endp -> nextp = nodep; Data.endp = nodep; nodep -> Node_Data = push_data; ++Data.List_Size; return *this; } Stack_l<Map_Type>& push(Map_Type& push_data) { Node *nodep = new Node(); nodep -> lastp = Data.endp; if (!Data.headp) { Data.headp = nodep; Data.endp = nodep; } else Data.endp -> nextp = nodep; Data.endp = nodep; nodep -> Node_Data = push_data; ++Data.List_Size; return *this; } Stack_l<Map_Type>& push(Map_Type* push_data) { Node *nodep = new Node(); nodep -> lastp = Data.endp; if (!Data.headp) { Data.headp = nodep; Data.endp = nodep; } else Data.endp -> nextp = nodep; Data.endp = nodep; nodep -> Node_Data = *push_data; ++Data.List_Size; return *this; } Stack_l<Map_Type>& push(const Map_Type* push_data) { Node *nodep = new Node(); nodep -> lastp = Data.endp; if (!Data.headp) { Data.headp = nodep; Data.endp = nodep; } else Data.endp -> nextp = nodep; Data.endp = nodep; nodep -> Node_Data = *(Map_Type*)push_data; ++Data.List_Size; return *this; } Stack_l<Map_Type>& pop(void) { if (Data.headp) { if (Data.List_Size == 1u) { delete Data.headp; Data.List_Size = 0; Data.headp = 0; Data.endp = 0; } else { Data.endp = Data.endp -> lastp; delete Data.endp -> nextp; Data.endp -> nextp = 0; --Data.List_Size; } } return *this; } Stack_l<Map_Type>& clear(void) { while (Data.List_Size) { pop(); } return *this; } Stack_l<Map_Type>(void) { /* NULL */ } Stack_l<Map_Type>(unsigned int data_size, Map_Type map_data) { Data.List_Size = data_size; while (data_size--) { Node *nodep = new Node(); nodep -> Node_Data = map_data; if (Data.headp) { nodep -> lastp = Data.endp; Data.endp -> nextp = nodep; Data.endp = nodep; } else { Data.headp = nodep; Data.endp = nodep; } } } Stack_l<Map_Type>(Stack_l<Map_Type>& map_data) { if (!map_data.empty()) { List_Data *listp = (List_Data*)map_data.data(); Node *nodep = listp -> headp, *newp; for (unsigned int i = 0; i != listp -> List_Size; ++i, nodep = nodep -> nextp) { newp = new Node(); newp -> Node_Data = nodep -> Node_Data; if (Data.headp) { newp -> lastp = Data.endp; Data.endp -> nextp = newp; Data.endp = newp; } else { Data.headp = newp; Data.endp = newp; } } Data.List_Size = listp -> List_Size; } } Stack_l<Map_Type>& operator=(Stack_l<Map_Type>& copy_data) { if (copy_data.empty()) return *this; List_Data *listp = (List_Data*)copy_data.data(); Node *nodep = listp -> headp, *newp; for (unsigned int i = 0; i != listp -> List_Size; ++i, nodep = nodep -> nextp) { newp = new Node(); newp -> Node_Data = nodep -> Node_Data; if (Data.headp) { newp -> lastp = Data.endp; Data.endp -> nextp = newp; Data.endp = newp; } else { Data.headp = newp; Data.endp = newp; } } Data.List_Size = listp -> List_Size; return *this; } bool operator==(Stack_l<Map_Type>& cmp_data) { if (cmp_data.size() != Data.List_Size) return false; else if (cmp_data.empty() && (!Data.List_Size)) return true; Node *nodep1 = Data.headp, *nodep2 = ((List_Data*)cmp_data.data()) ->headp; for (unsigned int i = 0; i != Data.List_Size; ++i, nodep1 = nodep1 -> nextp, nodep2 = nodep2 ->nextp) { if (nodep1 -> Node_Data != nodep2 -> Node_Data) return false; } return true; } bool operator!=(Stack_l<Map_Type>& cmp_data) { if (cmp_data.size() == Data.List_Size) return false; else if (cmp_data.empty() && (!Data.List_Size)) return false; Node *nodep1 = Data.headp, *nodep2 = ((List_Data*)cmp_data.data()) ->headp; for (unsigned int i = 0; i != Data.List_Size; ++i, nodep1 = nodep1 -> nextp, nodep2 = nodep2 ->nextp) { if (nodep1 -> Node_Data != nodep2 -> Node_Data) return true; } return true; } ~Stack_l<Map_Type>(void) { clear(); } }; /* Stack _ List */ template <typename Map_Type> class Stack_v /* Stack _ Vector */ { private: struct Node { Map_Type Node_Data; Node *nextp, *lastp; Node(void) { nextp = 0; lastp = 0; } }; struct List_Data { unsigned int List_Size; Node *headp, *endp; List_Data(void) { List_Size = 0; headp = 0; endp = 0; } }; struct Vector_Data { Map_Type *headp, *lastp, *endp; void resize(unsigned int data_size) { Map_Type *newp = new Map_Type[data_size](); endp = newp + data_size - 1; lastp = newp + (data_size > lastp - headp ? lastp - headp : data_size); if (headp) delete[] headp; headp = newp; } Vector_Data(void) { headp = 0; lastp = 0; endp = 0; } }Data; public: unsigned int size(void) { return Data.lastp - Data.headp; } Map_Type& top(void) { return *(Data.lastp - 1); } void* data(void) { return &Data; } bool full(void) { if (!Data.headp) return true; return Data.endp + 1 == Data.lastp; } bool empty(void) { if (!Data.headp) return true; return Data.headp == Data.lastp; } Stack_v<Map_Type>& push(Map_Type push_data) { if (full()) Data.resize((unsigned int)((Data.lastp - Data.headp) * 1.5) + 1); *Data.lastp = push_data; ++Data.lastp; return *this; } Stack_v<Map_Type>& push(Map_Type& push_data) { if (full()) Data.resize((unsigned int)((Data.lastp - Data.headp) * 1.5) + 1); *Data.lastp = push_data; ++Data.lastp; return *this; } Stack_v<Map_Type>& push(Map_Type* push_data) { if (full()) Data.resize((unsigned int)((Data.lastp - Data.headp) * 1.5) + 1); *Data.lastp = *push_data; ++Data.lastp; return *this; } Stack_v<Map_Type>& push(const Map_Type* push_data) { if (full()) Data.resize((unsigned int)((Data.lastp - Data.headp) * 1.5) + 1); *Data.lastp = *(Map_Type*)push_data; ++Data.lastp; return *this; } Stack_v<Map_Type>& pop(void) { if (empty()) { if (Data.lastp - Data.headp > 1) Data.resize((Data.lastp - Data.headp) >> 1); else return *this; } else --Data.lastp; return *this; } Stack_v<Map_Type>(void) { /* NULL */ } Stack_v<Map_Type>(unsigned int data_size, Map_Type map_data) { while (data_size) { push(&map_data); --data_size; } } Stack_v<Map_Type>(Stack_v<Map_Type>& map_data) { Vector_Data *datap = (Vector_Data*)map_data.data(); for (unsigned int i = 0, k = map_data.size(); i != k; ++i) push(datap -> headp + i); } Stack_v<Map_Type>& operator=(Stack_v<Map_Type>& copy_data) { if (copy_data.empty()) clear(); else { Vector_Data *datap = (Vector_Data*)copy_data.data(); for (unsigned int i = 0, k = copy_data.size(); i != k; ++i) push(datap -> headp + i); } return *this; } bool operator==(Stack_v<Map_Type>& cmp_data) { if (size() != cmp_data.size()) return false; else if (empty() && cmp_data.empty()) return true; Vector_Data *datap = (Vector_Data*)cmp_data.data(); for (unsigned int i = 0, k = size(); i != k; ++i) { if (*(Data.headp + i) != *(datap ->headp + i)) return false; } return true; } bool operator!=(Stack_v<Map_Type>& cmp_data) { if (size() != cmp_data.size()) return true; else if (empty() && cmp_data.empty()) return false; Vector_Data *datap = (Vector_Data*)cmp_data.data(); for (unsigned int i = 0, k = size(); i != k; ++i) { if (*(Data.headp + i) != *(datap -> headp + i)) return true; } return false; } Stack_v<Map_Type>& clear(void) { delete[] Data.headp; Data.headp = 0; Data.lastp = 0; Data.endp = 0; return *this; } ~Stack_v<Map_Type>(void) { delete[] Data.headp; } }; /* Stack _ Vector */ int main(void) { return 0; } (22029-xys)
|
16ms |
7.1 MiB |
|
370 Bytes |
2023-6-29 11:30:20 |
|
邵冠铖 (shaoguancheng22031)
|
16ms |
512 KiB |
|
253 Bytes |
2023-1-9 17:55:57 |
|
新壹街——陈学彬 (BUG)
|
16ms |
6.9 MiB |
|
353 Bytes |
2023-7-6 10:16:51 |
|
月下的九尾银狐
|
16ms |
6.9 MiB |
|
250 Bytes |
2023-9-9 11:24:35 |
|
郑岐蔚
|
16ms |
428 KiB |
|
290 Bytes |
2023-1-26 15:14:39 |
|
hyh22031
|
16ms |
384 KiB |
|
271 Bytes |
2023-1-9 17:58:35 |
|
wangjun
|
16ms |
6.9 MiB |
|
350 Bytes |
2023-11-29 12:36:57 |
|
时代一校-赵彦博 (zyb)
|
16ms |
7 MiB |
|
283 Bytes |
2023-12-3 14:08:32 |
|
爱情海校区—沙天一 (沙天一)
|
16ms |
7 MiB |
|
316 Bytes |
2023-7-9 9:17:21 |
|
我推的乱破 (贺俊楠)
|
16ms |
7 MiB |
|
387 Bytes |
2023-7-10 14:09:33 |
|
马渝杭 (mayuhang)
|
16ms |
6.9 MiB |
|
251 Bytes |
2023-8-10 18:56:41 |
|
黄梓轩 (huangzixuan)
|
16ms |
6.9 MiB |
|
331 Bytes |
2023-7-15 8:33:58 |
|
chenxiaozhun
|
16ms |
512 KiB |
|
332 Bytes |
2023-3-18 15:24:39 |
|
李晨希
|
16ms |
6.9 MiB |
|
341 Bytes |
2023-7-19 13:40:02 |
|
陈风亦 (chenfengyi)
|
17ms |
512 KiB |
|
296 Bytes |
2023-1-18 17:04:52 |
|
朱老师 (zyp)
|
17ms |
436 KiB |
|
358 Bytes |
2023-1-9 17:48:53 |
|
临时账户(dangdang)
|
17ms |
424 KiB |
|
398 Bytes |
2023-1-25 11:28:19 |
|
zzzrrrxxx
|
19ms |
7.2 MiB |
|
289 Bytes |
2023-12-17 16:22:35 |
|
liuchenning
|
28ms |
7.1 MiB |
|
272 Bytes |
2023-12-3 14:52:59 |
|
lizishuo
|
66ms |
532 KiB |
|
285 Bytes |
2024-2-18 14:38:41 |
|
zhangyouze (张佑泽)
|
68ms |
544 KiB |
|
268 Bytes |
2024-3-8 23:13:52 |
|
kongql
|
182ms |
9 MiB |
Python 3 |
263 Bytes |
2023-9-1 11:56:18 |
|
penghy
|
191ms |
9 MiB |
Python 3 |
164 Bytes |
2023-9-1 11:58:35 |
|
wzzjnb2012
|
209ms |
4 MiB |
Python 3 |
353 Bytes |
2022-11-28 23:14:29 |