Time Limit: 2000ms
Memory Limit: 512MB
J - Sorted Array Partitioning