Hercules had to clean the Augean stables that WERE filthy . They hadn't been cleaned in 30 years.
King Augeas said "If you clean my stables in a day, you will get a tenth of my cattle".
Hercules WAS shrewd. There was no way he could clean the stables in one day.
Hercules is building character by persevering and showing that he isn't just strong, he's also smart.
Hercules had an idea. He decided to BEND the river to flood the stables. Then the water would clean them.
By bending the river, Hercules HAS completed his task early. He's exited to RECEIVE his prize.
Time for my prize!
King Augeas went back on his promise of the cattle. Hercules didn't care because he had to finish his other labors. When he finished his other labors, he came back to kill the king and take his money which he used to found the Olympics.