Anonymous user
Strip whitespace from a string/Top and tail: Difference between revisions
Strip whitespace from a string/Top and tail (view source)
Revision as of 12:07, 4 March 2021
, 3 years ago→{{header|Kotlin}}: Note about predicate
(→{{header|Java}}: Rework a tiny bit. Remove raw `trim`. Add some help text.) |
(→{{header|Kotlin}}: Note about predicate) |
||
Line 1,251:
=={{header|Kotlin}}==
It is worth
Kotlin’s <code>trim</code> family of functions also optionally accept a predicate, which can further customize the stripping behavior, if Unicode whitespace is not what is desired.
<lang kotlin>fun main(args: Array<String>) {
|