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

7
LINES

< > BotCompany Repo | #1035102 // arrayIterator

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (65L/1K).

1  
static <A> ItIt<A> arrayIterator(A[] l) {
2  
  ret l == null ?: new ItIt<A> {
3  
    int i = 0;
4  
    public bool hasNext() { ret i < l.length; }
5  
    public A next() { ret l[i++]; }
6  
  };
7  
}

Author comment

Began life as a copy of #1029311

download  show line numbers  debug dex  old transpilations   

Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1035102
Snippet name: arrayIterator
Eternal ID of this version: #1035102/3
Text MD5: f00bc0ff91bc5341e0a8e64f2682ba9b
Transpilation MD5: 02f3de4987ec2aabc46825a8bd78d04d
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-03-30 01:24:51
Source code size: 186 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 62 / 95
Version history: 2 change(s)
Referenced in: [show references]