매일매일 IT
[JavaProgramming] Even Fibonacci numbers 본문
자바ㅠㅠ!! 피보나치 수열에서 짝수의 합 구하기
Each new term in the Fibonacci sequence is generated by adding the previous two terms.
By starting with 1 and 2, the first 10 terms will be:
1, 2, 3, 5, 8, 13, 21, 34, 55, 89, ...
By considering the terms in the Fibonacci sequence whose values do not exceed four million, find the sum of the even-valued terms.
'Programming Language > JAVA' 카테고리의 다른 글
[JavaProgramming] Sum square difference (0) | 2018.01.28 |
---|---|
[JavaProgramming] Smallest multiple (0) | 2018.01.28 |
[JavaProgramming] Largest palindrome product (0) | 2018.01.27 |
[JavaProgramming] Largest prime factor (0) | 2018.01.26 |
[JavaProgramming] Multiples of 3 and 5 (0) | 2018.01.26 |
Comments