Sequential synthesis by language equation solving