Anonymous user
Calendar: Difference between revisions
→{{header|D}}
(→{{header|ALGOL 68}}: added D) |
|||
Line 167:
=={{header|D}}==
{{works with|D|2}}
<lang d>import std.stdio, std.datetime, std.string, std.exception, std.conv
void main() {
Line 176:
enforce(1 <= cols && cols <= 12);
auto rows =
auto date = Date(year, 1, 1);
auto offs = cast(int)date.dayOfWeek();
|