substring(int beginIndex) is a Groovy function that pads a string with the spaces added to the right.
String substring(int Index)
The function takes in one parameter, Index. This is the beginning index.
The function returns the specified substring.
class Main {static void main(String[] args) {String result = "Edpresso";println(result.substring(4));}}
esso