Prompt user and allocate array