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

12
LINES

< > BotCompany Repo | #1009490 // differencesElementByElement_codeTokensOnly

JavaX fragment (include)

1  
static <A> L<Triple<A, A, Int>> differencesElementByElement_codeTokensOnly(L<A> a, L<A> b) {
2  
  L<Triple<A, A, Int>> l = new L;
3  
  if (l(a) != l(b)) ret l;
4  
  int n = l(a);
5  
  for (int i = 1; i < n; i += 2) {
6  
    A aa = a.get(i);
7  
    A bb = b.get(i);
8  
    if (neq(aa, bb))
9  
      l.add(triple(aa, bb, i));
10  
  }
11  
  ret l;
12  
}

Author comment

Began life as a copy of #1009488

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: #1009490
Snippet name: differencesElementByElement_codeTokensOnly
Eternal ID of this version: #1009490/1
Text MD5: 4a7add2a9833c930c45e2cbb56466331
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-08-04 17:50:10
Source code size: 325 bytes / 12 lines
Pitched / IR pitched: No / No
Views / Downloads: 492 / 520
Referenced in: [show references]