We saw a few operators in the introduction to this chapter, of which quite a few were string-related. Some of these capabilities are given within the System.String object as methods to offer a quicker way to perform some operations—such as splitting strings, joining strings, replacing strings, changing cases, creating substrings, removing substrings, and so on.
In this recipe, we will look at a few scenarios based on the input file we created in the Understanding Here-Strings recipe. A loop will not be required for these actions since they are simple, single operations. We will learn about looping through these files in the Flow Control using Branches and Loops chapter so that we can work with more complex scenarios.
Here are the operations that need to be performed on the input file:
- Remove the leading . in the paths. (Use the file you created...