However, sharecropping trapped ex-slaves into a cycle of debt that could see them working for their former masters for free and unable to leave their land. Black codes also reintroduced elements of slavery in terms of punishment, restrictions on freedom and penal servitude.