WHAT HAPPENS WHEN YOU TYPE “ls *.c” INTO YOUR SHELL

First of all, we have to understand every single character of the command in order to underestand it completly.

The “ls” command, referring to LIST, is the one that let us list all the files we have in our current directory. It let us know the name of the file, and main information if you combine it with some options to make it long format.

Then we have our wildcard, the “*”, which matches one or more occurrences of any character. Wildcards are symbols or special characters that represent other characters, that help us with selecting and working at multiple files at a time.

So, analyizing the command itself, we could understand that it is going to print us a list with only “.c” type files, in the current directory.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store