I think the usage of `partition` is correct here.