Bird Watcher possible error in tasks 3 to 7 examples

In the code samples for the Bird Watcher instructions for tasks 3 to 7 use birds-per-day. For example, task 3 says:

Implement the inc-bird function to increment today’s count:

(inc-bird birds-per-day)
;;=> [2 5 0 7 4 2]

Shouldn’t they be using last-week instead of birds-per-day? (birds-per-day is defined as a function to return a single number in task 2, but last-week is a fixed vector defined in task 1)

Hmm, I can’t find this. Here is what I see for the second task:

(def birds-per-day [2 5 0 7 4 1])
(today birds-per-day)
;;=> 1

last-week is also framed as last week’s counts, not this week’s counts. It’d be confusing me to mention incrementing today’s count and then use a previous week’s counts.

Ah, you’re right! I had totally misread that :sweat_smile:

Well, I don’t blame anyone that misreads this exercise. There are several issues:

  • Defining birds-per-day as global means it’s not expected to pass it as an argument to functions, which is exactly what is shown for tasks 2-6.

  • Functions and variables are not using intuitive names.

  • The last task is confusing. The expected/intended solution is to use the equals sign to check the function argument against the vector [1 0 1 0 1 0 1]. Yet, we can find all sorts of overcomplicated approaches, which clearly indicates that people are misunderstanding the task.

It is a learning exercise exclusive for the track, so if there are ways that you think that can be improved to help learners then you totally should propose changes. :+1: