It is interesting that these dimwitted people were under the impression that they were the ones higher and superior and better-guided as compared to Muslims, therefore, they surmised that the prayer they were making was in their own favour. They actually wanted that Allah would, through their prayer, give His verdict as to who was true and who was false. Thus, when they win, their victory would become the Divine verdict on their being on the side of truth.
But, they did not know that the prayer they were making was really a curse for their own selves, and that it was a supplication for the good of Muslims. After the end of the battle came, the Qur'an told them: إِن تَسْتَفْتِحُوا فَقَدْ جَاءَكُمُ الْفَتْحُ (If you pray for victory, "victory" has come upon you) that is, 'if you are looking for a Divine verdict, that is before you - truth has triumphed and falsehood has been defeated. Then: وَإِن تَنتَهُوا فَهُوَ خَيْرٌ لَّكُمْ (if you give up it is better for you) that is, 'now is the time when, if you abandon your disbelief and hostility, it will turn out to be better for you.' And, if you still decide to revert back to your wickedness and the threat of armed aggression, then, Allah too will revert back and support Muslims: وَإِن تَعُودُوا نَعُدْ (And if you repeat, We shall repeat). In that case, the consequence would be: وَلَن تُغْنِيَ عَنكُمْ فِئَتُكُمْ شَيْئًا وَلَوْ كَثُرَتْ (And your people shall not suffice you at all, even though they are many in number) that is, 'your numerical superiority and group strength shall be of no avail against the help and, support given by Allah.' As for the help and support of Allah: ti; (Allah is with the believers) that is, 'how can any group or power work for you when Allah Ta` ala, the very possessor of absolute power, is with the Muslims?'