Purposeful segregation

Why do cultural and racial groups purposefully segregate themselves and exclude other cultures and races after fighting for so long to be included?