Is it permissible for one to masturbate in order not to commit fornication?
This is called committing the milder of the two evils such as eating a carcass in fear of death, and this happens when committing fornication is very likely to occur.
Does fasting on behalf of a deceased person permissible?
Fasting on belhaf of a deceased person is permissible, since the Prophet (PBUH) said: "Whoever dies while he still has some fasts to make up (of the days of Ramadan), then his heir (any of them) should fast on his behalf." [Agreed upon]. The previous answer is for making up missed obligatory fasts on behalf of the deceased. But if the fasting on behlaf of the deceased was for performing a voluntary acts of devotion such as fasting....is permissible as adopted by the majority of Muslim scholars and based on the above hadith as they stated "Every good dead intended to be on behalf of the deceased its reward will reach the latter." And Allah Knows Best.
What is the ruling on someone who perform their prayer after finishing it because they believe they missed a Rak'a, a prostration, or that they did not perform it correctly (thinking their prayer was invalid)?
If he was sure that his prayer is void then reperforming it is an obligation along with figuring out the reason of invalidity so long as this wasn't out of uncertainty. And Allah Knows Best.
A woman committed adultery with several men and gave birth to a baby. Who is the father?
All perfect praise be to Allah the Lord of the Worlds. May His peace and blessings be upon our Prophet Mohammad and upon all his family and companions.
The adulterers must be punished as prescribed in Sharia for they have incurred the wrath of Almighty Allah. Therefore, they must hasten to make repentance and ask Allah for forgiveness. However, the child born out of this unlawful relation is attributed to the mother. And Allah The Almighty Knows Best.