Created
February 23, 2018 17:52
-
-
Save AnthonyMikh/8d6c97de0faa2cf5b096177c3cbb98e5 to your computer and use it in GitHub Desktop.
Решение задачи №73 от UniLecs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tribonacci = 0:0:1:zipWith3 (\x y z -> x+y+z) tribonacci (tail tribonacci) (drop 2 tribonacci) | |
solutions = 0:drop 4 tribonacci | |
solution = (solutions !!) | |
main = print . solution $ 4 -- 13 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Обоснование решения (сравнение с решением "в лоб"):
Вывод: