Sa'īd he instructed that the two prostrations be performed before the concluding salutation.
Another reason is that he said there:
“If he has prayed five units, the two prostrations will make his prayer even in number; and if he has prayed the full four, they will humiliate Satan.”
This makes clear that he proceeds on the basis of certainty while remaining unsure whether he has prayed more or fewer units—whether he has prayed four or five. It also makes clear the benefit of the two prostrations in either of these two mutually exclusive cases.
In the hadith of Ibn Mas'ūd, he said:
“Let him exercise his judgment to determine what is correct, complete his prayer on that basis, and then perform two prostrations.”
Another wording states:
“Let him complete his prayer on that basis, then give the concluding salutation, and then perform two prostrations.”
He thus regarded what the worshipper did after exercising his judgment as completing his prayer, and described him here as completing his prayer without being in doubt about it.
However, the word “doubt” sometimes refers to anything short of certainty, even when there are indications and supporting evidence for it. Indeed, concerning his statement:
“We have more right to doubt than Abraham,”
it has been said that he described a state short of the reassurance of heart that Abraham sought as “doubt,” even though Abraham was certain and had no doubt that undermined his certainty. Thus, when his Lord asked him, “Do you not believe?” he replied, “Yes, but so that my heart may be reassured.” And Allah Most High said:
“Thus We showed Abraham the dominion of the heavens and the earth, so that he might be among those of sure faith.”
If even such a state has been called “doubt” in his statement, “We have more right to doubt than Abraham,” then what of someone who has no certainty? Thus, whoever acts on the stronger of two proofs