Number Sequence HDU-1005
Problem Description A number sequence is defined as follows:f(1) = 1, f(2) = 1, f(n) = (A * f(n - 1) + B * f(n - 2)) mod 7.Given A, B, and n, you are to calculate the value of f(n).Input The i...
原创
2018-04-16 16:15:40 ·
164 阅读 ·
0 评论