Skip to content

Instantly share code, notes, and snippets.

Last active Jul 15, 2016
What would you like to do?
Windows multithreading in c++
//more details:
#include <Windows.h>
#include <process.h>
#include <stdio.h>
unsigned int __stdcall test_thread(void *data) {
printf("Thread Started");
return 0;
int main()
HANDLE myhandle = (HANDLE) _beginthreadex(NULL, 0, &test_thread, NULL, 0, 0);
WaitForSingleObject(myhandle, INFINITE);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment