Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
@mmangiamusardo please mark your post as having spoiler content next time.
This comment is hidden because it contains spoiler information about the solution
.Length returns the total length of the string starting from 1. We need to access the index which begins at 0. If we wanted to access the last index of the original string it would be Length-1. Since we want to cut the last character off, we use -2. Hope that helps
This comment is hidden because it contains spoiler information about the solution
The first character is the other of the two.
The solution is taking a substring starting from the second character and a number of charachers after that equal to the length of the full string minus two.
Example:
You want
234
, which is three characters long. You tell it to skip the first character and then take the three characters after the first one. Therefore it is the length of the full string minus two.