Now that we've learned the basics of file and directory navigation, let's learn how we can display and edit files, search for text within files and more. In the Windows GUI, if we want to open a file and view its contents, we can just double click on the file. Depending on the file type, it will open on a default application. In Windows, text files default to open in an application called notepad. But we can change this if we want to. To change the default application that opens files, just right click and click Properties. Under 'Open with', we can change the application to another text editor, like Word Pad. Most of the files that we'll be dealing with throughout this course, will be text and configuration files. So, let's just focus on those files instead of images, music files, etc. Viewing the contents of a file in PowerShell is simply using the 'cat' command, which stands for concatenate. Let's give it a try. This will dump the contents of the file into our shell. This isn't the best solution for a file since it just keeps writing the content until the whole file is displayed. If we want to view the contents of the file one page at a time, we can use the 'more' command, like this. The 'more' command will get the contents of the file but will pause once it fills the terminal window. Now, we can advance the text at our own pace. When we run the 'more' command, were launched into a separate program from the shell. This means that we interact with the more program with different keys. The Enter key advances the file by one line. You can use this if you want to move slowly through the file. Space advances the file by one page. A page in this case depends on the size of your terminal window. Basically, 'more' will output enough content to fill the terminal window. The q key allows you to quit out of 'more' and go back to your shell. If we want to leave the 'more' command and go back to our shell, we can just hit the q key. Here we are. Now, what if we just wanted to view part of the file? Let's say we want to quickly see what the first few lines of the text file are. We don't really want to open up the whole file. Instead, we just want to get a glimpse of what the document is. This is called the head of the file. To do this, we can go back to 'cat' and add the -Head parameter. This will show us the first 10 lines of the file. Now, what if we wanted to view the last few lines or the tail of the file? I bet you can guess what you are going to do. This will show us, by default, the last ten lines of the file. Again, these two commands don't seem like they have any immediate use to you yet. We'll see their benefits when we work with logs in an upcoming lesson. Now, let's take a look at how to do these same tasks in Linux.