Minimax-optimal Inference from Partial Rankings