added alternate code for implementing 3 stacks from one array