锘??xml version="1.0" encoding="utf-8" standalone="yes"?>久久久精品2019免费观看,一本伊大人香蕉久久网手机,久久93精品国产91久久综合http://m.shnenglu.com/meglory/category/13998.htmlzh-cnSat, 12 Mar 2011 08:25:25 GMTSat, 12 Mar 2011 08:25:25 GMT60綰︾憻澶幆http://m.shnenglu.com/meglory/archive/2011/03/11/141582.htmlmeglorymegloryFri, 11 Mar 2011 10:55:00 GMThttp://m.shnenglu.com/meglory/archive/2011/03/11/141582.htmlhttp://m.shnenglu.com/meglory/comments/141582.htmlhttp://m.shnenglu.com/meglory/archive/2011/03/11/141582.html#Feedback0http://m.shnenglu.com/meglory/comments/commentRss/141582.htmlhttp://m.shnenglu.com/meglory/services/trackbacks/141582.html
 1 #include<stdio.h>
 2 #include<stdlib.h>
 3 
 4 struct node{
 5     int value;
 6     struct node* next;
 7 };
 8 typedef struct node NODE;
 9 typedef NODE* NODEPTR;
10 
11 int main()
12 {
13     int i;
14     int count;
15     int N,M;
16     NODEPTR head=(NODEPTR)malloc(sizeof(NODE));
17     NODEPTR prePtr=head;
18     NODEPTR currPtr;
19     NODEPTR temp;
20 
21     scanf("%d %d",&N,&M);
22     count=N;
23 
24     for(i=1;i<=N;i++)
25     {
26         currPtr=(NODEPTR)malloc(sizeof(NODE));
27         currPtr->value=i;
28         prePtr->next=currPtr;
29         prePtr=currPtr;
30     }
31 
32     currPtr->next=head->next;
33     currPtr=head->next;
34 
35     while(count--)
36     {
37         for(i=1;i<=M-2;i++)
38             currPtr=currPtr->next;
39 
40         temp=currPtr->next;
41         printf("%d is out\n",temp->value);
42         currPtr->next=temp->next;
43         currPtr=currPtr->next;
44         free(temp);
45     }
46 
47 
48     return 0;
49 }
50 



meglory 2011-03-11 18:55 鍙戣〃璇勮
]]>
鍗遍櫓鐨剉ector::erasehttp://m.shnenglu.com/meglory/archive/2011/03/11/141568.htmlmeglorymegloryFri, 11 Mar 2011 07:41:00 GMThttp://m.shnenglu.com/meglory/archive/2011/03/11/141568.htmlhttp://m.shnenglu.com/meglory/comments/141568.htmlhttp://m.shnenglu.com/meglory/archive/2011/03/11/141568.html#Feedback0http://m.shnenglu.com/meglory/comments/commentRss/141568.htmlhttp://m.shnenglu.com/meglory/services/trackbacks/141568.html 1 #include<iostream>
 2 #include<vector>
 3 using namespace std;
 4 
 5 int main()
 6 {
 7     vector<int> a;
 8     a.push_back(1);
 9     a.push_back(2);
10     a.push_back(3);
11     a.push_back(4);
12     a.push_back(5);
13     
14     vector<int>::iterator pos=a.begin()+2;
15     vector<int>::iterator temp=pos+1;
16     cout<<"temp now is"<<*temp<<endl;
17     
18     a.erase(pos);
19     
20     cout<<"temp now is"<<*temp<<endl;
21     
22     system("pause");
23     return 0;
24 }

浠婂ぉ鍦ㄧ敤STL鍐欑害鐟熷か闂鐨勬椂鍊欙紝鍙戠幇vector鐨勮涓烘繪槸浜х敓璇″紓鐨勭粨鏋滐紝璁╂垜鐧炬濅笉寰楀叾瑙c?br>
鐪嬩笂闈唬鐮侊細
涓涓獀ector閲岄潰鏈?鍒?錛屾誨叡5涓厓绱犮傛妸涓涓凱浠e櫒pos鎸囧悜絎笁涓厓绱?錛屽彟澶栦竴涓猼emp鎸囧悜絎洓涓厓绱?錛岀劧鍚庤皟鐢╡rase鎶婄涓変釜鍏冪礌鎶規帀銆?br>娉ㄦ剰錛屽湪榪欎釜鏃跺欑戶緇В寮曠敤temp鐨勬椂鍊欙紝浼氬彂鐜板畠鎸囧悜鐨勫厓绱犵濂囩殑鍙樻垚浜?銆?br>
闂灝卞鍦╡rase涓婇潰錛屽湪C++ Reference涓婇潰鍐欓亾錛?br>Because vectors keep an array format, erasing on positions other than the vector end also moves all the elements after the segment erased to their new positions, which may not be a method as efficient as erasing in other kinds of sequence containers (deque, list).

This invalidates all iterator and references to elements after position or first.

鍒犻櫎vector涓涓厓绱狅紝瀵艱嚧瀹冨悗闈㈢殑鍏冪礌鍏ㄩ儴縐誨姩鍒版柊鐨勪綅緗紝鎵浠ュ鑷磋繖涓厓绱犱箣鍚庣殑鎵鏈夎凱浠e櫒閮藉け鏁堛?br>

鍦ㄤ嬌鐢ㄤ竴涓嚱鏁板墠搴旇瀵瑰畠鐨勮涓烘湁娓呮鐨勪簡瑙c傝皚璁般?/p>

meglory 2011-03-11 15:41 鍙戣〃璇勮
]]>
printf鐨勮繑鍥炲?/title><link>http://m.shnenglu.com/meglory/archive/2010/12/23/137277.html</link><dc:creator>meglory</dc:creator><author>meglory</author><pubDate>Thu, 23 Dec 2010 03:39:00 GMT</pubDate><guid>http://m.shnenglu.com/meglory/archive/2010/12/23/137277.html</guid><wfw:comment>http://m.shnenglu.com/meglory/comments/137277.html</wfw:comment><comments>http://m.shnenglu.com/meglory/archive/2010/12/23/137277.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://m.shnenglu.com/meglory/comments/commentRss/137277.html</wfw:commentRss><trackback:ping>http://m.shnenglu.com/meglory/services/trackbacks/137277.html</trackback:ping><description><![CDATA[<div style="background-color: #eeeeee; font-size: 13px; border: 1px solid #cccccc; padding: 4px 5px 4px 4px; width: 98%;"><!--<br><br>Code highlighting produced by Actipro CodeHighlighter (freeware)<br>http://www.CodeHighlighter.com/<br><br>--><span style="color: #008080;"> 1</span> <span style="color: #000000;">#include</span><span style="color: #000000;"><</span><span style="color: #000000;">stdio.h</span><span style="color: #000000;">></span><span style="color: #000000;"><br></span><span style="color: #008080;"> 2</span> <span style="color: #000000;"><br></span><span style="color: #008080;"> 3</span> <span style="color: #000000;"></span><span style="color: #0000ff;">int</span><span style="color: #000000;"> main()<br></span><span style="color: #008080;"> 4</span> <span style="color: #000000;">{<br></span><span style="color: #008080;"> 5</span> <span style="color: #000000;">    </span><span style="color: #0000ff;">int</span><span style="color: #000000;"> i</span><span style="color: #000000;">=</span><span style="color: #000000;">43</span><span style="color: #000000;">;<br></span><span style="color: #008080;"> 6</span> <span style="color: #000000;">    printf(</span><span style="color: #000000;">"</span><span style="color: #000000;">%d</span><span style="color: #000000;">"</span><span style="color: #000000;">,printf(</span><span style="color: #000000;">"</span><span style="color: #000000;">%d</span><span style="color: #000000;">"</span><span style="color: #000000;">,printf(</span><span style="color: #000000;">"</span><span style="color: #000000;">%d</span><span style="color: #000000;">"</span><span style="color: #000000;">,i)));<br></span><span style="color: #008080;"> 7</span> <span style="color: #000000;">    <br></span><span style="color: #008080;"> 8</span> <span style="color: #000000;">    </span><span style="color: #0000ff;">return</span><span style="color: #000000;"> </span><span style="color: #000000;">0</span><span style="color: #000000;">;<br></span><span style="color: #008080;"> 9</span> <span style="color: #000000;">}<br></span><span style="color: #008080;">10</span> <span style="color: #000000;"><br></span><span style="color: #008080;">11</span> <span style="color: #000000;">榪欐槸涓涓ぞ鍖虹殑楠岃瘉鐮侊紝璁╄緭鍑虹粨鏋滐紝寰堟湁鎰忔濄?br></span><span style="color: #008080;">12</span> <span style="color: #000000;">緇撴灉鏄?321.<br></span><span style="color: #008080;">13</span> <span style="color: #000000;">printf()鐨勮繑鍥炲鹼細On success, the total number of characters written </span><span style="color: #0000ff;">is</span><span style="color: #000000;"> returned.<br></span><span style="color: #008080;">14</span> <span style="color: #000000;">On failure, a negative number </span><span style="color: #0000ff;">is</span><span style="color: #000000;"> returned.</span></div> <br><img src ="http://m.shnenglu.com/meglory/aggbug/137277.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://m.shnenglu.com/meglory/" target="_blank">meglory</a> 2010-12-23 11:39 <a href="http://m.shnenglu.com/meglory/archive/2010/12/23/137277.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item><item><title>C璇█澹版槑鐨勭鍣ㄨВ鐮佺幆http://m.shnenglu.com/meglory/archive/2010/06/09/117507.htmlmeglorymegloryWed, 09 Jun 2010 15:09:00 GMThttp://m.shnenglu.com/meglory/archive/2010/06/09/117507.htmlhttp://m.shnenglu.com/meglory/comments/117507.htmlhttp://m.shnenglu.com/meglory/archive/2010/06/09/117507.html#Feedback0http://m.shnenglu.com/meglory/comments/commentRss/117507.htmlhttp://m.shnenglu.com/meglory/services/trackbacks/117507.html浠婂ぉ鐪嬪埌鏈変綅绔ラ瀷鍦═opLanguage涓婇潰鎻愪簡涓棶棰橈細
int a[][3]={1,2,3,4,5,6};
int (*b)[3]=a;

涓嶇敤緙栬瘧鍣紝璇磋b閲屾槸浠涔堬紵

鍏跺疄榪欑闂鍦ㄣ奀涓撳緙栫▼銆嬬殑P65涓殑紲炲櫒瑙g爜鐜腑鏈夊緢璇﹀敖鐨勮В閲娿?br>鍦ㄨ繖閲岄鍏堣冨療絳夊紡宸﹁竟鐨刬nt (*b)[3]

1.鏈宸﹁竟鐨勬爣璇嗙鏄痓 琛ㄧずb鏄?..
2.b鐨勫乏杈規槸*
琛ㄦ槑b鏄寚鍚?..鐨勬寚閽?br>
3.*鐨勫乏杈規槸宸︽嫭鍙?
宸︽嫭鍙鋒妸宸茬粡澶勭悊鐨勯儴鍒嗗0鏄庣粍鍚堝湪涓璧鳳紝鐭ラ亾閬囪鐩稿簲鐨勫彸鎷彿
4.(*b)宸﹁竟鏄柟鎷彿
琛ㄧず澶у皬涓?鐨勬暟緇?
5.鍓╀笅鐨勭鍙峰艦鎴愬熀鏈被鍨媔nt
琛ㄦ槑b鏄竴涓寚閽堬紝瀹冩寚鍚戜竴涓ぇ灝忎負3鐨刬nt鍨嬫暟緇勩?

鑰屾妸a鐨勫艱祴緇檅錛岃〃鏄庢槸灝哹鎸囧悜a銆?br>
涔嬪悗sagasw緇欏嚭涓涓猟emo,鍙互鏇存竻妤氱殑浜嗚В鎸囬拡鐩稿叧鍚勭銆?br>
int main(int argc, char* argv[])
{

    
int a[][3]={1,2,3,4,5,6};
    
int (*b)[3]=a;   
    printf(
"a %p b %p \n", a, b);

    
++b;
    printf(
"a1 %p a10 %p a11 %p b %p \n", a[1], &a[1][0], &a[1][1], b);

    
++b;
    printf(
"a %p b %p \n", a[2], b);
    
return 0;

}



meglory 2010-06-09 23:09 鍙戣〃璇勮
]]>
C++杈撳嚭姹夊瓧http://m.shnenglu.com/meglory/archive/2010/05/12/115228.htmlmeglorymegloryWed, 12 May 2010 13:45:00 GMThttp://m.shnenglu.com/meglory/archive/2010/05/12/115228.htmlhttp://m.shnenglu.com/meglory/comments/115228.htmlhttp://m.shnenglu.com/meglory/archive/2010/05/12/115228.html#Feedback0http://m.shnenglu.com/meglory/comments/commentRss/115228.htmlhttp://m.shnenglu.com/meglory/services/trackbacks/115228.html//杈撳嚭姹夊瓧
char temp[3];
char c;

temp[
0]=getchar();
temp[
1]=getchar();
temp[
2]='\0';
    
cout
<<temp<<endl;


meglory 2010-05-12 21:45 鍙戣〃璇勮
]]>
无码人妻精品一区二区三区久久久| 久久成人永久免费播放| 999久久久免费精品国产| 久久线看观看精品香蕉国产| 久久国产精品偷99| 久久99精品国产麻豆宅宅| 国产欧美一区二区久久| 精品国产日韩久久亚洲| 2021久久国自产拍精品| 麻豆精品久久久久久久99蜜桃 | 久久国产美女免费观看精品| 国产A三级久久精品| 成人a毛片久久免费播放| 精品多毛少妇人妻AV免费久久| 免费观看成人久久网免费观看| 无码人妻久久一区二区三区蜜桃| 国产精品无码久久久久久| 亚洲国产精品一区二区三区久久| 久久精品国产福利国产秒| 久久亚洲精品无码AV红樱桃| 久久精品免费全国观看国产| 办公室久久精品| 久久九九亚洲精品| 久久精品国产99国产精偷| 欧美牲交A欧牲交aⅴ久久| 热久久视久久精品18| 久久国产成人亚洲精品影院 | 久久久久亚洲AV无码专区网站| 国内精品久久久久影院日本| 热久久最新网站获取| 久久国内免费视频| 一本久道久久综合狠狠躁AV| 欧美精品一区二区久久| 久久精品无码专区免费| 久久WWW免费人成—看片| 国产精品va久久久久久久| 久久精品一区二区| 99精品久久久久久久婷婷| 久久精品国产秦先生| 91精品国产高清久久久久久91| 青青青伊人色综合久久|