Open In App

select command in Linux with examples

Improve
Improve
Improve
Like Article
Like
Save Article
Save
Share
Report issue
Report

select command in Linux is used to create a numbered menu from which a user can select an option. If the user enters a valid option then it executes the set of command written in select block and then ask again to enter a number, if a wrong option is entered it does nothing. If user enters nothing and simply press ‘enter‘ the option menu gets printed.

Syntax:

select NAME [in WORDS ... ;] do COMMANDS; done

Example:

Options:

  • help select : It displays help information.


Last Updated : 27 May, 2019
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads