1 | static MultiSet<Char> charsHistogram(S s) { |
2 | new MultiSet<Char> ms; |
3 | int n = l(s); |
4 | for i to n: ms.add(s.charAt(i)); |
5 | ret ms; |
6 | } |
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1008499 |
Snippet name: | charsHistogram - MultiSet<Char> of chars in string |
Eternal ID of this version: | #1008499/1 |
Text MD5: | b423c50018d1d34327a74380dda75848 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-05-20 12:34:03 |
Source code size: | 136 bytes / 6 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 453 / 504 |
Referenced in: | [show references] |