You are viewing a single comment's thread. Return to all comments →
the first line contains an integer, 'n', denoting the number of elements in the sequence.
The second line contains 'n' space-separated integers denoting the respective values of p(1) , p(2) , ... p(n).
constraints:
1<=n<=50
1<=p(x)<=50 ; 1<= x <=n
suppose we input n=6, x will vary from 1 to n but p(x) can be anything from 1-50
Seems like cookies are disabled on this browser, please enable them to open this website
Sequence Equation
You are viewing a single comment's thread. Return to all comments →
the first line contains an integer, 'n', denoting the number of elements in the sequence.
The second line contains 'n' space-separated integers denoting the respective values of p(1) , p(2) , ... p(n).
constraints:
1<=n<=50
1<=p(x)<=50 ; 1<= x <=n
suppose we input n=6, x will vary from 1 to n but p(x) can be anything from 1-50