This method deletes a sub string from within a string.
string1 − The source string.
count − The count of characters to keep in the string.
This method returns the string after deletion of the characters post the count of characters.
/* Main program */ a = "Hello World" say delstr(a,6)
When we run the above program, we will get the following result.