Height and the number of leaf sets has nothing to do with sexing plants. Regardless of height or number of leaves, the plant has to be sexually mature. In plants that are not autos, it generally takes 4-8 weeks to show sex. Sexual maturity is denoted by alternating nodes.
The females will have two white hairs like in the picture posted. Males grow football shaped things.
We generally just destroy the males as they are good for nothing except pollination. I would not keep a male and a female in the same house.