June 2018 Update
This commit is contained in:
parent
ba8067c3b7
commit
22f33d4004
5278 changed files with 84726 additions and 14379 deletions
1
Task/Show-the-epoch/ABAP/show-the-epoch-2.abap
Normal file
1
Task/Show-the-epoch/ABAP/show-the-epoch-2.abap
Normal file
|
|
@ -0,0 +1 @@
|
|||
cl_demo_output=>display( |Result: { CONV datum( 0 ) }| ).
|
||||
|
|
@ -1 +1,2 @@
|
|||
println("Time zero (the epoch) is ", strftime("%c", 0), ".")
|
||||
using Base.Dates
|
||||
println("Time zero (the epoch) is $(unix2datetime(0)).")
|
||||
|
|
|
|||
9
Task/Show-the-epoch/Lingo/show-the-epoch.lingo
Normal file
9
Task/Show-the-epoch/Lingo/show-the-epoch.lingo
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
now = the systemDate
|
||||
put now
|
||||
-- date( 2018, 3, 21 )
|
||||
|
||||
babylonianDate = date(-1800,1,1)
|
||||
|
||||
-- print approx. year difference between "babylonianDate" and now
|
||||
put (now-babylonianDate)/365.2425
|
||||
-- 3818.1355
|
||||
|
|
@ -1,11 +1,11 @@
|
|||
/*REXX program shows the # of days since the epoch for the DATE function*/
|
||||
/*REXX program displays the number of days since the epoch for the DATE function (BIF). */
|
||||
|
||||
say ' today is' date() /*today's is format: mm MON YYYY */
|
||||
say ' today is: ' date() /*today's is format: mm MON YYYY */
|
||||
|
||||
days=date('Basedate') /*only 1st char of option is used*/
|
||||
say right(days,35) "days since the REXX base date of January 1st, year 1"
|
||||
days=date('Basedate') /*only the first char of option is used*/
|
||||
say right(days, 40) " days since the REXX base date of January 1st, year 1"
|
||||
|
||||
say 'and today is:' date(,days,'B') /*this should be today (still). */
|
||||
|
||||
/*──────── The above statement is only valid for the newer REXXes,*/
|
||||
/*──────── older versions don't support the 2nd and 3rd arguments.*/
|
||||
say ' and today is: ' date(, days, "B") /*it should still be today (µSec later)*/
|
||||
/* ↑ ┌───◄─── This BIF (Built-In Function) is only */
|
||||
/* └─────────◄──────┘ for newer versions of REXX that */
|
||||
/* support the 2nd and 3rd arguments. */
|
||||
|
|
|
|||
4
Task/Show-the-epoch/Stata/show-the-epoch.stata
Normal file
4
Task/Show-the-epoch/Stata/show-the-epoch.stata
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
. di %td 0
|
||||
01jan1960
|
||||
. di %tc 0
|
||||
01jan1960 00:00:00
|
||||
Loading…
Add table
Add a link
Reference in a new issue