Please help me i just want to ask

Yes it is possible.

You would need a char array at least as big as the maximum number of key presses you want to store.
You would maintain two indices or pointers to the array.
One would point to the first used location in the array and one would point to the last used location in the array.
You would write functions to 'push' characters into the array or 'pop' them off.
You also need to know when the array is empty or full and it is handy to have a 'peek' function that tells you what the next character to be popped will be without actually popping it.
You can make the array behave as First In First Out (FIFO) or Last In First Out (LIFO) depending on how you manipulate the pointers.