str_repeat n::int s::string = string $ take n $ cycle (s:[]);