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

5
LINES

< > BotCompany Repo | #1024442 // iteratorCount_int

JavaX fragment (include)

1  
static <A> int iteratorCount_int(Iterator<A> i) {
2  
  int n = 0;
3  
  if (i != null) while (i.hasNext()) { i.next(); ++n; }
4  
  ret n;
5  
}

Author comment

Began life as a copy of #1019727

download  show line numbers  debug dex  old transpilations   

Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1024442
Snippet name: iteratorCount_int
Eternal ID of this version: #1024442/1
Text MD5: 788d51f4d4d79e7527d0cb8605359528
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-08-12 20:22:25
Source code size: 133 bytes / 5 lines
Pitched / IR pitched: No / No
Views / Downloads: 250 / 294
Referenced in: [show references]