Created
May 3, 2021 08:24
-
-
Save Tynael/d3ebfd079fde3da3c99668434955567f to your computer and use it in GitHub Desktop.
C++ Code Example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <time.h> | |
#include <windows.h> | |
#include <stdlib.h> | |
int main() { | |
struct tm * tmp; | |
time_t s; | |
for (;;) { | |
s = time(NULL); | |
tmp = localtime( & t); | |
printf("%d:%0d:%d\n", tmp -> tm_hour, tmp -> tm_min, tmp -> tm_sec); | |
Sleep(1000); | |
system("cls"); | |
} | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Example used for: https://neutrondev.com/5-popular-programming-languages-and-their-uses/