@Arjun Sir pls check this ans
1.((s, a, ε)---> (s, a))
2.((s, b, ε)---> (s, a))
3.((s, a, ε)---> (f, ε))
4.((f, a, a)---> (f, ε))
5.((f, b, a)---> (f, ε))
option A--- aaa
(s,a,ε)---transition 1-->(s,a)
(s,a,a)---transition 3-->(f,a) //just consume the input and move to final state
don't change stack symbol
(f,a,a)---transition 4-->(f,ε) //pop the topmost symbol
since the stack is empty now and string is also complelety read so it is accepted
option C--- baaba
(s,b,ε)---transition 2-->(s,a) //read symbol b and push a onto stack
(s,a,a)---transition 1-->(s,a) // just consume the input without seeing the stack symbol
and push a onto stack
(s,a,ε)---transition 3-->(f,a)// just consume the input without seeing the stack symbol
and move to final state
(f,b,a)---transition 5-->(f,ε) //pop the top of stack
(f,a,a)---transition 4-->(f,ε) //pop the top of stack
since the stack is empty now and string is also complelety read so it is accepted
option D--- bab
(s,b,ε)---transition 1-->(s,a)
(s,a,a)---transition 3-->(f,a) //just consume the input and move to final state
don't change stack symbol
(f,a,a)---transition 4-->(f,ε) //pop the topmost symbol
since the stack is empty now and string is also complelety read so it is accepted
Option B—aabab
(s,a,ε)---transition 1-->(s,a) //read symbol a and push a onto stack
(s,a,a)---transition 3-->(s,a) // just consume the input without seeing the stack symbol
and move to final state
(s,b,a)---transition 5-->(f, ε)// pop the top of stack
Now we are stuck as no move is defined so this is not accepted by PDA