Some algorithms of C++