HTML and CSS Reference
In-Depth Information
using OPeratOrs and exPressiOns
A
conditional operator
compares one
value to another using a
logical operator
.
If the condition is true
,
the conditional
operator returns the
f
i
first value
; otherwise,
it returns the
second
v
alue
.
The values of the
daysLeft
,
hrsLeft
,
minsLeft
, and
secsLeft
elements are
calculated using
Date
object methods.
altafulla/Shutterstock.com; jbdphotography/Shutterstock.com