helloworld.cpp 401 B

12345678910111213141516171819
  1. // Copyright (C) 2001-2003
  2. // William E. Kempf
  3. //
  4. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  5. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  6. #include <boost/thread/thread.hpp>
  7. #include <iostream>
  8. void helloworld()
  9. {
  10. std::cout << "Hello World!" << std::endl;
  11. }
  12. int main()
  13. {
  14. boost::thread thrd(&helloworld);
  15. thrd.join();
  16. }