The Exam
Time limit1sMemory limit128 MB
Arrange the numbers 1 to n so the smallest gap between neighbors is as large as possible, and print that gap or NIE when it is below k.
Problem
Professor Byteoni is preparing the Bit & Byte Theory exam. He has already written questions and gave each one an expected difficulty coefficient. The coefficients are the natural numbers to , and no two questions share a coefficient.
Now he is deciding in what order the questions go on the paper. He wants his students to judge the difficulty of every question on their own, so he plans to line the questions up so that the coefficients of two consecutive questions differ by at least . He also wants to know how strict such a requirement can get on questions.
Input
The first and only input line contains two integers and (, ): the number of questions the professor prepared and the smallest difference he wants between the coefficients of two consecutive questions.
Output
Print one line with the largest integer such that all questions can be lined up so that the coefficients of every two consecutive questions differ by at least . If that is smaller than , the professor cannot meet his own requirement, so print the single word NIE (Polish for no) instead.