Depending on the API/language you use, splitting the string "ABCD"
using ""
as a delimiter gets you:
["A", "B", "C", "D"]
in Java, Javascript, and Go["", "A", "B", "C", "D", ""]
in Rust["ABCD"]
in C#- Fails with an Exception in Python3
From the perspective of formal language design, what is the correct result of such an operation? Is it defined?
Disclosure: This question was posted at stack overflow but was closed as opinion-based. I was directed to post my question here instead.
formal-languages
tag was probably a mistake. $\endgroup$