#include <windows.h> #include <iostream> #include <cstdlib> using namespace std; DWORD WINAPI FunProc(LPVOID lpParameter) { float * p; while (p == p) { (*p++)+1.144564542315345; } return 0; } int main(int argc, char **argv) { HANDLE hThread; for (int i = 0; i < 4; i++) { hThread = CreateThread(NULL, 0, FunProc, &i, 0, NULL); CloseHandle(hThread); } system("pause"); return 0; }