I have to make a non-continuous integer sequence a_1, a_2, ..., a_n which satisfies
{a_1, a_2, ..., a_n} ∈ [1, n]
|a_i - a_(i-1)| > 1
How to make it? I appreciate you a hint or some help. Thanks 🙂
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
When there’re less than 4 elements, it is impossible to do.
When there’re 4 or more elements, we can construct the sequence like this:
if n is even:
if n is odd:
Now that n is equal or large than 4, |1-n| = |n-1| >= 3, |1-(n-1)| = |1-n+1| = |n| >= 4, the sequence satisfies the constraint.