ide:https://ide.codingblocks.com/s/632673
algorithm is correct but not able to solve what changes should be done in code to resolve this
Check for error in code
just use next_permutation(a,a+N); function
Reference Code
ide:https://ide.codingblocks.com/s/632673
algorithm is correct but not able to solve what changes should be done in code to resolve this
just use next_permutation(a,a+N); function
Reference Code