Libraryless. Click here for Pure Java version (2714L/17K).
1 | // convert things like "18-8" to "18-24, 0-8" |
2 | static L<IntRange> splitBusinessHoursAtMidnight(L<IntRange> l) { |
3 | ret concatLists(map(l, r -> |
4 | r.end < r.start && r.start > 12 |
5 | ? ll(intRange(r.start, 24*60), intRange(0, r.end)) |
6 | : ll(r)); |
7 | } |
Began life as a copy of #1028626
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1030447 |
Snippet name: | splitBusinessHoursAtMidnight |
Eternal ID of this version: | #1030447/1 |
Text MD5: | 7104af910c1cd6d7423e305b38f2114e |
Transpilation MD5: | c24154443babbf9d3712079487b68ffd |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-12-17 20:36:28 |
Source code size: | 257 bytes / 7 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 183 / 246 |
Referenced in: | [show references] |