- objective: Learn how to use the ls *.c command
First let's talk about what does the 'ls' command do. The 'ls' command will list all files in your current working directory like this:
The * acts as a wildcard that in this case will be used to filter what type of file we want to display. The option for the 'ls' command '*.c' will act as a filter that will only display files that end with the format ".c". for example:
As you can now see, all the files that end with the format '.txt' were not displayed and all files that end with the format '.c' have been listed.
No comments:
Post a Comment