possible bug in timelist?

13 views
Skip to first unread message

stefano cerbioni

unread,
Jul 28, 2022, 5:13:39 AM7/28/22
to The Ring Programming Language
hi i want print  a
?TimeList()[5]
but return me july   that is  ?TimeList()[4]  why ? o_O

stefano cerbioni

unread,
Jul 28, 2022, 5:19:10 AM7/28/22
to The Ring Programming Language
in windows return me this

Thu Jul 28 11:18:00 2022

but in manual i have this
05/24/15 09:58:38
o_O

Mansour Ayouni

unread,
Jul 28, 2022, 5:19:54 PM7/28/22
to stefano cerbioni, The Ring Programming Language
Hello Stefano,

Use the TimeInfo() function instead:

load "stdlibcore.ring"
? timeInfo(:date)
? timeInfo(:time)
? timeInfo(:hour_12)
And this is a list of all possible params:
:hour_24
:hour_12
:minutes
:seconds
:time
:day_short
:day_long
:month_short
:month_long
:date_time
:day
:day_year
:month_year
:am_pm
:week_year
:day_week
:date
:year_century
:year
:time_zone
:percent_sign
Link to documentation:
https://ring-lang.github.io/doc1.16/stdlib.html#timeinfo
Best,
Mansour

--

---
You received this message because you are subscribed to the Google Groups "The Ring Programming Language" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ring-lang+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ring-lang/c811c171-aead-4b85-8491-1cf0a8793b96n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages