IMPORTANCE OF TIME

https://ide.codingblocks.com/s/430880 ,

please check my code, same output is same but test cases are not passing,

hello @CODER_JATIN

dont use stack , it will reverse the order.

check updated code here ->

bhaiya lekin element ko last mai kese bhejenge fir bina stack use kiye?

Acha Acha samajh gya , matlab usi queue mai firse push krdenge, i am right?

push front element to the back of queue and then pop the front thats it

yeah. . .
…
…
. . .

and bhaiya , there is one question “Find the Greater Element” , usko mene ar to liya lekin array se kara hai…to uski koi or approach bta do , smjh ni aa rha vo

use stack. . . . . …
solve similar problems first before attempting it.