No, the cohort of potential miscreants is large enough that locking up perpetrators for longer has no statistically significant impact on crime rates and longer sentences don't act as a deterrent.If we apply the same concept to the whole population it still works.