CVW - Editorial

PROBLEM LINK:

CodeChef: Practical coding for everyone

Author: acesprime

Tester: acesprime

Editorialist: acesprime

DIFFICULTY:

MEDIUM.

PREREQUISITES:

Array

PROBLEM:

Problem is to arrange numbers from 1 to N in such a way that absolute value of difference of the ith number from the position of ith number in the arrangement , to be equal to a certain value K.

AUTHOR’S AND TESTER’S SOLUTIONS:

GU7uLE - Online Java Compiler & Debugging Tool - Ideone.com