I have a 5 gallon with blue Dream shrimp. They are closely related to cherry shrimp. I estimate Ihat I have at least 20 shrimp in the tank. There are a lot of hiding places in my tank so I would not be surprised if there are 30 or more in the tank (adults and juveniles).
If you have as many as 1 male and 1 female, you will end up with many shrimps. But I do suggest buying a few more than 2.
When you clean the tank, always check the bucket for babies. They are very small and a sort of off white colour when first hatched. I empty the bucket with a jug to check. Yes it does take a while but I don't want to throw any shrimps down the drain.
I've also sucked up adult shrimps........