February 2019
Intermediate to advanced
626 pages
15h 51m
English
The Insert method is able to add one string into another. This method expects an index from the beginning of the string, counting from 0, and a string to insert, as follows:
$string = 'The letter of the alphabet is a' $string.Insert(4, 'first ') # Insert this before "letter", include a trailing space
The Remove method removes characters from a string, based on a start position and the length of the string to remove:
$string = 'This is is an example' $string.Remove(4, 3)
The previous statement removes the first instance of is, including the trailing space.
Read now
Unlock full access