rohan's submission of Magnet Sort | CodeChef