Add method to get partition of number