fix max_k problem (need to do +1 for hypothetical)