Is there a foreach construct in the Go language?
Can I iterate over a slice or array using a for?
Is there a foreach construct in the Go language? Can I iterate over a
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
From For statements with range clause:
As an example:
If you don’t care about the index, you can use
_:The underscore,
_, is the blank identifier, an anonymous placeholder.