beibarys.17's blog

By beibarys.17, history, 6 years ago, In English

Please help on this problem:

We denote the function F by:

\begin{cases} F(x) = 1 & x\leq 2 \\ F(x) = F(x — 1) + F(x — 2) + x & x > 2 \end{cases}

Given q (1 ≤ q ≤ 105) queries. The queries are characterized by two numbers l, r (1 ≤ l ≤ r ≤ 109). Find:

Full text and comments »

  • Vote: I like it
  • +10
  • Vote: I do not like it

By beibarys.17, history, 6 years ago, In English

Hello Codeforces community!

Please help on this problem:

Given array with length N (1 ≤ N ≤ 105, 1 ≤ ai ≤ 109). And given Q queries(1 ≤ Q ≤ 105). For each query given one number X. (1 ≤ X ≤ 1014). Find number of subarrays which sum equals to X.

Sorry for my poor English.

Full text and comments »

  • Vote: I like it
  • +26
  • Vote: I do not like it