Skip to content

counting and nesting - number of weeks #1

@andypalmer

Description

@andypalmer

; :week-year is still a puzzle (t-> "2017" (nest :week)) t-sequence count) => 52?

From https://en.wikipedia.org/wiki/ISO_week_date, there are 53 weeks if December 31st is a Thursday, or if December 31st is a Wednesday and it's a leap year

I tried changing the tests, but I'm not familiar enough with Clojure yet, and (t->"2017" (nest :week) t-sequence) results in an empty set.

I suspect that it requires a mappable nesting in metajoda.clj, but the combinations I tried had no effect. It might also be an ambiguity between "2017" as a year and as a week-year.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions