Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add entries to Map #271

Merged
merged 2 commits into from
May 3, 2020
Merged

add entries to Map #271

merged 2 commits into from
May 3, 2020

Conversation

ymmooot
Copy link
Contributor

@ymmooot ymmooot commented May 3, 2020

Hi mint-lang 🍃.
Map has keys and values but no entries so I added.
It's very useful to iterate maps.

@s0kil
Copy link
Contributor

s0kil commented May 3, 2020

@ymmooot Thank You 🍃

@s0kil s0kil merged commit 0c04876 into mint-lang:master May 3, 2020
@gdotdesign
Copy link
Member

@ymmooot thanks :)

Probably you don't know but you can iterate on maps using the for loop as well:

for (key, value of map) {
  ...
} 

Here is an example: https://sandbox.mint-lang.com/sandboxes/9C6pcDPdUmWzLA


And now checking it it's not documented 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants