Last week i copied some string splitting logic from C# to Java and didn't bother to test much. Today i fired up one of the Duet appointments and typed max value in the location field (256) and it bombed! .. after debugging i found
C# substring is - substring(startIndex, length)
Java substring is - substring(startIndex, endIndex)
crap.. Java's is more like Python's where it's called slice syntax - str[startIndex:endIndex]
but we don't have slice syntax in Java or C# .. and i like C#'s better
No comments:
Post a Comment