Hi! I’m clsung

Hi! I’m clsung

clsung’s blog site, or you can call me AlanSung

Hi! I’m clsung RSS Feed
 
 
 
 

Posts tagged c++

how to clear ostringstream?

下面這程式真有清掉嗎?

ostringstream os;

os.clear();
cerr << os.str()

openmp tutorials - scheduling

目前會的,就是 在 for loop 中, schedule 設為 dynamic 與 guided 的不同。


string to/from wstring conversion

std::wstring s2ws(const std::string& s)
{
    std::wstring temp(s.length(),L‘ ‘);
    std::copy(s.begin(), s.end(), temp.begin());
    return temp;
}

std::string ws2s(const std::wstring& s)
{
    std::string temp(s.length(), ‘ ‘);
    std::copy(s.begin(), s.end(), temp.begin());
    return temp;
}

Update: 好心人提供的文章


噗浪:

  • clsung 說 中午吃海龍珠,不錯。值得再去吃。 29 mins 前
  • clsung 正在 大安森林公園旁的 *$ 上網 5 hours 前
  • clsung 說 晚餐在家吃羊肉火鍋 :-D 2008/11/22

分類

Flickr

    clsung. Get yours at bighugelabs.com/flickr

Blogroll

    馬的警總回來了
Creative Commons Attribution-NonCommercial-ShareAlike 2.5 Taiwan
Creative Commons Attribution-NonCommercial-ShareAlike 2.5 Taiwan