I am facing a slight problem in my project. I have a menu driven program and one of my options is Display all, which displays all the entries from a map using a loop. The display is on the terminal and I am not being able to view all the entries because it only shows the last few entries before my prompt comes again. I want the output to be redirected to a file so that I can use more commands and give the user a view accordingly. Please suggest few commands or code.
Redirection of output from the terminal to a file in unix/linux
vi