Removing elements from an array is not as straightforward as adding elements to an array. Adding two arrays is as simple as using the + arithmetic operator or the += assignment operator. Removing objects, on the other hand, can be done in either of the following two ways:
- Filter out objects that you do not want and assign the rest of the array to a new array
- Use the System.Collections.ArrayList class
Create a list of all the files and directories within ~/random. Remove the paths within dir-04.