Strip whitespace from a string/Top and tail: Difference between revisions
Strip whitespace from a string/Top and tail (view source)
Revision as of 18:35, 1 November 2020
, 3 years agono edit summary
(Added Wren) |
No edit summary |
||
Line 323:
return str;
}</lang>
=={{header|BaCon}}==
{{works with|QBasic}}
<lang qbasic>
'---Remove leading whitespace
PRINT CHOP$(" String with spaces "," ",1)
'---Remove trailing whitespace
PRINT CHOP$(" String with spaces "," ",2)
'---Remove both leading and trailing whitespace
PRINT CHOP$(" String with spaces "," ",0)
</lang>
=={{header|BASIC}}==
|