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

7
LINES

< > BotCompany Repo | #1001539 - sortByIndex - sort by elenent at index

JavaX fragment (include)

static void sortByIndex(L<L> l, final int index) {
  sort(l, new Comparator<L>() {
    public int compare(L a, L b) {
      ret cmp(a.get(index), b.get(index));
    }
  });
}

download  show line numbers  debug dex  old transpilations   

Travelled to 12 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz

No comments. add comment

Snippet ID: #1001539
Snippet name: sortByIndex - sort by elenent at index
Eternal ID of this version: #1001539/3
Text MD5: c19c9389a327a9f3d0ea0e8377c7ff5d
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-04-22 17:03:37
Source code size: 180 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 484 / 617
Version history: 2 change(s)
Referenced in: [show references]

Formerly at http://tinybrain.de/1001539 & http://1001539.tinybrain.de