Black Codes grew out of Slave Codes, or laws that defined the civil status of African Americans prior to and after the Civil War. They also prevented African Americans from having equal access to education. South Carolina was the first state to establish Black Codes that specifically addressed education of free African Americans. All states added these codes to the state constitution. The codes resulted in varying educational outcomes from state to state. Depending on state regulations, blacks were relegated to segregated education by law, could attend mixed schools, were denied admission to schools, or could found privately funded schools for their own education. Blacks began to challenge Black Codes by filing suits against school systems; for example, in 1855 they succeeded in dismantling segregated school laws in Massachusetts. Throughout the nineteenth century, blacks protested in many states, such as Iowa, Indiana, and Illinois, and overturned de jure segregation in education. Although the Brown v. Board of Education of Topeka, Kansas decision of 1954 and cases in other states declared segregation in schools illegal, de facto segregation continues.