随笔分类 -  快速幂

摘要:DescriptionIn the Fibonacci integer sequence,F0= 0,F1= 1, andFn=Fn− 1+Fn− 2forn≥ 2. For example, the first ten terms of the Fibonacci sequence are:0, ... 阅读全文
posted @ 2015-08-05 22:05 Painting、时光 阅读(169) 评论(0) 推荐(0)
摘要:问题描述作为史上最强的刷子之一,zhx的老师让他给学弟(mei)们出n道题。zhx认为第i道题的难度就是i。他想要让这些题目排列起来很漂亮。zhx认为一个漂亮的序列{ai}下列两个条件均需满足。1:a1..ai是单调递减或者单调递增的。2:ai..an是单调递减或者单调递增的。他想你告诉他有多少种排... 阅读全文
posted @ 2015-03-15 19:13 Painting、时光 阅读(197) 评论(0) 推荐(0)