Display Date in Shell

Level 14 keystrokes

date displays the current date and time.

Shell code

# Prints the current date and time, e.g. Mon Jan 15 10:30:45 UTC 2024
# The format can be chosen with +, e.g. date +%Y-%m-%d
1date

Output

Mon Jan 15 10:30:45 UTC 2024
Practice typing this code

Practice typing this code. Results are not recorded in the rankings.

More Shell examples at level 1

← Shell typing practice