Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

cin EOF Linux

 ÎÒΪʲôдÕâ¸öÌâÄ¿ÄØ£¬ÒòΪÎÒ½ñÌìҪдµÄ²©ÓëÕâÈýÕ߶¼ÓйØϵ£¬ÖÁÉÙÎÒ¸öÈËÈÏΪÊÇÕâÑùµÄ¡£
ÓиöÈËÎÊÁËÒ»¸öÕâÑùµÄС³ÌÐò£¬ËµÓÐÎÊÌ⣺
#include <iostream>
#include <vector>
#include <string>
using namespace std;
int main()
{
vector <string*> spvec;
string str;
cout <<"input string" <<endl;
while(cin>>str)
{
//cin>>str;
string *pstr=new string;
*pstr=str;
spvec.push_back(pstr);
}
vector <string*>::iterator it=spvec.begin();
while(it != spvec.end())
{
cout <<**it <<" " <<(**it).size() <<endl;
++it;
}
it=spvec.begin();
while(it != spvec.end())
{
delete *it;
it++;
}
return 0;
}

Õâ¶Î³ÌÐòÎÒÈÏΪÊÇûÓÐÎÊÌâµÄ£¬ÎÒÔÚVS2008ϺÍubuntu g++ 4.4.1ÏÂÊÔ¹ýÊÇûÓÐÎÊÌâµÄ¡£Ïë²»Ã÷°×ÄÇÈËÊÇÔõÑùµÄ¡£ÎÒ¾õµÃÊÇËûÔÚÊäÈëEOFʱ³öÁËÎÊÌâ°É¡£  ÔÚWindowsÏÂÓà Ctrl+Z , ÔÚLinuxÏÂÓà Ctrl+D .
ÎÒ¾õµÃ¾ÍÊÇËûÔÚLinuxÏÂÊäÈë³öÁËÎÊÌâ¡£


Ïà¹ØÎĵµ£º

LinuxÉ豸ģÐÍÖ®input×ÓϵͳÏê½â

Ò»£ºÇ°ÑÔ
×î½üÔÚÑо¿androidµÄsensor driver£¬Ö÷ÒªÊÇE-compass£¬ÆäÖÐÓõ½ÁËLinux input×Óϵͳ.ÔÚÍøÉÏÒ²¿´Á˺ܶàÕâ·½ÃæµÄ×ÊÁÏ£¬¸Ð¾õ»¹ÊÇÕâƪ·ÖÎöµÄ±È½ÏϸÖÂ͸³¹£¬Òò´ËתÔØÒ»ÏÂÒÔ±ã×Ô¼ºÑ§Ï°£¬Í¬Ê±ºÍ´ó¼Ò·ÖÏí£¡
£¨Õâƪ²©¿ÍÖ÷ÒªÊÇÒÔ¼üÅÌÇý¶¯ÎªÀýµÄ£¬²»¹ý½²½âµÄÊÇLinux Input Subsystem£¬¿ÉÒÔ×ÐϸµÄÑо¿Ò»Ï£¡£©
¼üÅÌÇý¶¯½«¼ì ......

LinuxϵͳÈÕÖ¾¹¦Äܼ°Æä¹ÜÀíÏê½â

 ±ÈÌØÍøתÔØ£ºhttp://datacenter.chinabyte.com/308/11039308.shtml
        ÈÕÖ¾¶ÔÓÚ°²È«À´Ëµ£¬·Ç³£ÖØÒª£¬Ëû¼Ç¼ÁËϵͳÿÌì·¢ÉúµÄ¸÷ÖÖ¸÷ÑùµÄÊÂÇ飬Äã¿ÉÒÔͨ¹ýËûÀ´¼ì²é´íÎó·¢ÉúµÄÔ­Òò£¬»òÕßÊܵ½¹¥»÷ʱ¹¥»÷ÕßÁôϵĺۼ£¡£ÈÕÖ¾Ö÷ÒªµÄ¹¦ÄÜÓУºÉó¼ÆºÍ¼à²â¡£Ëû»¹¿ÉÒÔʵʱµÄ¼à²âÏµÍ³×´Ì ......

linuxÖÐmount¹²Ïísmbfs

 ×ª×Ô£ºhttp://www.neatstudio.com/show-365-1.shtml
ÔÚubuntuÏÂÃæĬÈÏÊDz»ÄÜmount samba¹²ÏíµÄĿ¼µÄ£¬¶øÔÚ¹«Ë¾ÀÎÒ²»µÃ²»Á¬½ÓÕâÑùµÄĿ¼£¬ÔÚwindowsÏÂÃæµÄʱºò£¬samba¹²Ïí¾ÍÏówindowsµÄ¹²ÏíĿ¼ÄÇÑùµÄ·½±ã£¬µ«ÊÇÔÚlinuxÏÂÃæ¾Í²»ÊÇÕâÑùµÄÁË¡£
Ê×ÏÈ£¬ÄãÒªÏÂÔØsmbmount,ÔËÐÐ £º
apt-get install smbfs
È»ºó¾Í»á°² ......

Redhat Linux Ó²Å̹ÒÔØ·½·¨£¡£¡£¡

 ²Î¿¼×ÊÁÏ£ºhttp://www.blogjava.net/lijun_li/archive/2009/04/02/263491.html   
               http://www.chinalinuxpub.com/read.php?wid=1080
Ó²Å̹ÒÔزÙ×÷¹¤×÷²½Ö裺
1¡¢ÏȲ鿴Ŀǰ»úÆ÷ÉÏÓм¸¿éÓ²ÅÌ£¬²é¿´ÃüÁîÓÐÁ½ ......

LinuxϵͳÖзÀ»ðǽµÄ¹Ø±Õ¼°¿ªÆô

ÖØÆôºóÉúЧ
¿ªÆô£º chkconfig iptables on
¹Ø±Õ£º chkconfig iptables off
2) ¼´Ê±ÉúЧ£¬ÖØÆôºóʧЧ
¿ªÆô£º service iptables start
¹Ø±Õ£º service iptables stop
ÐèҪ˵Ã÷µÄÊǶÔÓÚLinuxϵÄÆäËü·þÎñ¶¼¿ÉÒÔÓÃÒÔÉÏÃüÁîÖ´ÐпªÆôºÍ¹Ø±Õ²Ù×÷¡£
ÔÚ¿ªÆôÁË·À»ðǽʱ£¬×öÈçÏÂÉèÖ㬿ªÆôÏà¹Ø¶Ë¿Ú£¬
ÐÞ¸Ä/etc/sysconf ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ