### Operators
eq = $(filter $1,$2)
slice = $(wordlist 2,$(words $1),$1)
repl = $(if $(call eq,$(words $4),$1),$3,$(call repl,$1,$2,$3 $2,$(words $4) $4))
map = $(if $2,$(call map,$1,$(call slice,$2),$3,$4 $(call $1,$(firstword $2),$3,$4)),$4)
rotate = $(call slice,$1) $(firstword $1)
zip3 = $(if $2,$(call zip3,$1,$(call slice,$2),$(call rotate,$3),$(call rotate,$4),$5 $(call $1,$(firstword $2),$(firstword $3),$(firstword $4))),$5)
inc = $(words $(call repl,$1,_) _)
### Program body
count = $(words $3)
cycle = $(call slice,$(call repl,$1,_)) $2
fizz := $(call cycle,3,fizz)
buzz := $(call cycle,5,buzz)
numbers := $(call map,inc,$(call map,count,$(call repl,100,_)))
select = $(if $1,$1,$2)
fizzbuzz = $(call select,$(if $(call eq,$2,_),,$2)$(if $(call eq,$3,_),,$3),$1)
result := $(call zip3,fizzbuzz,$(numbers),$(fizz),$(buzz))
println = $(info $1)
### Targets
.PHONY: all
all: ; $(call map,println,$(result))
>how long did it take you to write fizzbuzz solution the first time?
Maybe a minute or two? I had already been programming for a few years by that point, so I were familiar with modulo.
>is it even a valid interview question
For entry-level positions, sure. But they will usually have different variants, such as fizz buzz jazz, or buzzfizz etc.
>So lets say a brainlet can spend several hours figuring it out and then it will take him 2 minutes in the interview to type it out?
They will usually ask other questions too though.