Better structure for take 5 $ repeat 1 example