Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

7
LINES

< > BotCompany Repo | #1007565 - put - short for Map.put or List.set (if in range)

JavaX fragment (include)

static <A, B> void put(Map<A, B> map, A a, B b) {
  if (map != null) map.put(a, b);
}

static <A> void put(L<A> l, int i, A a) {
  if (l != null && i >= 0 && i < l(l)) l.set(i, a);
}

Author comment

Began life as a copy of #1007435

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: #1007565
Snippet name: put - short for Map.put or List.set (if in range)
Eternal ID of this version: #1007565/4
Text MD5: bd5cbd8d348105cf23adddb1ba082ffa
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-04-03 19:43:50
Source code size: 188 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 412 / 432
Version history: 3 change(s)
Referenced in: [show references]