Video Coming Soon...

Created by Zed A. Shaw Updated 2026-11-26 20:48:52
 

47: date

WARNING: This is from the Go course but I'm rewriting the code and the description to fit C. If you want to attempt it go ahead. The challenge is the same, just no examples yet.

The date command is deceptively simple, and there are two layers to its difficulty. One way to approach this is to just "Go with it" and use Go's default formatting and date output. You could make that version of date very easily.

The other way to do this is to attempt to implement all of the formatting and output styles that the original supports. GNU date uses an older style of date formatting that requires far more work since it's not directly supported by Go.

I'd say, if you want to learn how to use Go date/time facilities, then just do the first one. If you want to learn how to write code that parses complex inputs then try to replicate GNU's date.

Previous Lesson Next Lesson

Register for From Impostor to Programmer

Register today for the course and get the all currently available videos and lessons, plus all future modules for no extra charge.