RosettaCodeData/Task/Associative-array-Iteration/Uiua/associative-array-iteration...

6 lines
420 B
Plaintext

x ← .map [3 9 7] {"foo" "bar" "hey"} # Using the example from the 'Creation' page
.⊟°map x # Decouple the hashmap and put a copy of it on the stack
&p.⊢ # Get the keys as a new array and print them
&p⊣: # Get the values as a new array and print them
&p⧅◌ # Get keys mapped to values