Return Value of get_time()

This function does not return any value after its execution. It just stores the input data into the given argument.

std::get_time() Function in C++

In C++, the function std::get_time() is a standard library function that is used to parse the given input as date and time value as specified in the format string that is passed as the argument. It stores that parsed time in the object of the tm type.

std::get_time() is defined inside <ctime> header in C++.

Similar Reads

Syntax of get_time()

get_time(tm* var, const CharT* format);...

Parameters of get_time()

This function accepts two parameters:...

Return Value of get_time()

This function does not return any value after its execution. It just stores the input data into the given argument....

Example of get_time() in C++

The below program demonstrates how to use the get_time() function in C++:...

Important Points About get_time()

It is used to parse the given input as date and time value as specified in the format string that is passed as the argument.The format string can contain conversion specifiers, whitespace characters, and ordinary characters (except %). Each ordinary character should match one character in the input stream.Each conversion specification starts with a % character, optionally followed by an E or O modifier (which is ignored if not supported by the locale), and then followed by a character that determines the behavior of the specifierThe format specifiers are the same as that of POSIX function strptime()....