Skip to content

Instantly share code, notes, and snippets.

@vialyx
Created February 28, 2018 07:20
Show Gist options
  • Save vialyx/2dd1c767acaf4c6bbcb98bd9627c02e0 to your computer and use it in GitHub Desktop.
Save vialyx/2dd1c767acaf4c6bbcb98bd9627c02e0 to your computer and use it in GitHub Desktop.
for (index, user) in allUsers.enumerated() {
print("User: \(user) at index: \(index)")
/*
User: User(name: "Admin") at index: 0
User: User(name: "Guest") at index: 1
*/
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment