solve using dawg