create a compare string function and attach each domain with their state list