Dear Dhirendra,
Whether be an employee be in his notice period, but if the salary will be paid to him of that period, it will be Net Amount (after all the deductions, including gratuity too). So, the Gratuity will be paid to him. And the last date of working is always considered as THE DATE OF RELEAVING after the completion of notice period. So, it will be definitely counted.