You are given a function f(n)=2×7n/2×cos(nθ)+n×4n, where θ=tan−1√32.
You are also given two integers p and q. Your task is to find the value of n=q∑n=pf(n) (modulo 109+21).
Input format
Output format
Print T lines each containing a single integer corresponding to the required value n=q∑n=pf(n). Print the answer modulo 109+21.
Constraints
1≤T≤1020≤p≤q≤1018
f(0)=2f(1)=8S=f(0)+f(1)=10