Write a function called sumsquares_list which receives a vector of int and returns the sum of the squares of the elementes in the list. For example, if we have a vector with the values x with values [1,2,3,4,5], sumsquares_list(x) would return 55 since 1 + 4 + 9 + 16 + 25 is 55. GitHub … Continue reading #Quiz08 →
Write a function called sumsquares_list which receives a vector of int and returns the sum of the squares of the elementes in the list. For example, if we have a vector with the values x with values [1,2,3,4,5], sumsquares_list(x) would return 55 since 1 + 4 + 9 + 16 + 25 is 55. GitHub … Continue reading #Quiz08 →
Write a function called fibonacci which receives a lon “n” and returns a long which is the value of the nth number in the fibonacci series which is: 0,1,1,2,3,5,8,13,21,34,55,89………. So, fibonacci(0) woud return 0, fibonacci(5) would return 5, fibonacci(8) would return 21. Note that the first two fibonacci numbers are 0 and 1. All others … Continue reading #Quiz07 →
Write a function called fibonacci which receives a lon “n” and returns a long which is the value of the nth number in the fibonacci series which is: 0,1,1,2,3,5,8,13,21,34,55,89………. So, fibonacci(0) woud return 0, fibonacci(5) would return 5, fibonacci(8) would return 21. Note that the first two fibonacci numbers are 0 and 1. All others … Continue reading #Quiz07 →