Is it right that this prints "1"?: ```val tags = "...
# getting-started
j
Is it right that this prints "1"?:
Copy code
val tags = "".split(" ")
println(tags.size) //prints 1
👌 12
j
you ask to split a string with a separator that is not contained within the string, so the
split
method simply returns the same string, non-splitted it doesn’t matter if you’re doing this on an empty string or not
Copy code
val tags = "".split(" ")
println(tags.size) //prints 1
Copy code
val tags = "test".split(" ")
println(tags.size) //prints 1
👍 1