Duty Leave
CodeChefOpen on judge ↗
Our University is planning to give DL(Duty Leave) to all the students. I know you got it already but it's happening again. But this time they give you a list of N numbers and you need to rearrange the given list and give it back. If a student's list has two adjacent odd numbers or two adjacent even number DL would not be given to him. Since you are a smart student you need to tell whether you will
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start