Generic Stack and Queue implementation needed

 
I am looking for code to implement both queues and stacks on MT4.  I realize they are built in and available on MT5 as part of the Standard Library under Data Collections (CQUEUE, and CSTACK).  I am assuming these MT5 resources cannot be used in MT4, so I am wondering if anyone has implemented this in MT4?  Would appreciate any help here.