Static arrays have the lifetime of the program. When the Operating system cleans up the ended program, it deallocates the memory with it.
If it is dynamic memory (e.g. TShoe is a class), the OS still deallocates, but it can be beneficial to deallocate it out of housekeeping reasons (*). Then you''l probably want to walk the array and .free them.
(*) In my work app, I have nearly all deallocations under ifdef, an ifdef that I only enable for debugging purposes.