Libraryless. Click here for Pure Java version (2958L/19K).
1 | sS dropFirstSpacedColumns(int n, S text) { |
2 | S re = "^\\s*" + repString(n, "\\S+\\s*"); |
3 | ret mapEachLine(text, line -> regexpReplace_direct(line, re, "")); |
4 | } |
5 | |
6 | static IF1<S> dropFirstSpacedColumns(int n) { |
7 | ret text -> dropFirstSpacedColumns(n, text); |
8 | } |
download show line numbers debug dex old transpilations
Travelled to 5 computer(s): bhatertpkbcr, ekrmjmnbrukm, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1030041 |
Snippet name: | dropFirstSpacedColumns |
Eternal ID of this version: | #1030041/4 |
Text MD5: | b50bdac92a58c5e612f9b05f337a3d34 |
Transpilation MD5: | 840961b6be25496bc9dbf63460da4427 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-11-10 14:06:36 |
Source code size: | 261 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 233 / 319 |
Version history: | 3 change(s) |
Referenced in: | [show references] |