March 2018
Beginner to intermediate
416 pages
9h 24m
English
The mktime function converts the datespec string into a timestamp of the same format as returned by the systime() function, the number of seconds elapsed since the epoch. The datespec is a string of the YYYY MM DD HH MM SS format :
$ vi mktime.awkBEGIN { print "Number of seconds since the Epoch" print "mktime(\"2018 01 15 20 20 10\") : " mktime("2014 12 14 30 20 10")}$ awk -f mktime.awk
The output of the execution of the previous code is as follows:
Number of seconds since the Epochmktime("2018 01 15 20 20 10") : 1418604610
Read now
Unlock full access