Let's say I have the following string:
String = "0123456789abcdefg";
How can I split it in blocks of 5, so that I get an array of string like
["01234", "56789", "abcde", "fg"]
Notice the last string is 2 characters long.
Is there a simple way to do so in Java?