1 | static O[] repArrayF(int n, O f, O... args) {
|
2 | O[] o = new O[n]; |
3 | for i to n: |
4 | o[i] = callF(f, args); |
5 | ret o; |
6 | } |
7 | |
8 | static O[] repArrayF(O f, int n) {
|
9 | ret repArrayF(n, f); |
10 | } |
Began life as a copy of #1007438
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: | #1011514 |
| Snippet name: | repArrayF - call a function repeatedly, collect into array |
| Eternal ID of this version: | #1011514/3 |
| Text MD5: | c54125cba09fa5129e7d44d76615787f |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-10-30 22:19:37 |
| Source code size: | 187 bytes / 10 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 620 / 637 |
| Version history: | 2 change(s) |
| Referenced in: | [show references] |