# Thread get_id() function in C++

C++Server Side ProgrammingProgramming

In this tutorial, we will be discussing a program to understand thread get_id() function in C++.

Thread get_id() function verifies the current state of the process and then returns the id for the current thread in execution. This function doesn’t take any parameters.

## Example

#include <chrono>
#include <iostream>
using namespace std;
}
int main(){
}
ID associated with thread1= 135456142132844
ID associated with thread2= 135121414221716