Last active
February 3, 2026 20:19
-
-
Save dacr/ecaff8e993ba6dadfc28eb0aec7ddd39 to your computer and use it in GitHub Desktop.
nix list / published by https://github.com/dacr/code-examples-manager #729edcf0-c5d4-41cd-a977-541f4399952f/1505529e62b5cc6c292bedf9a27e9f2f486fa998
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## summary : nix list | |
| ## keywords : nix, list | |
| ## publish : gist | |
| ## authors : David Crosson | |
| ## license : Apache License Version 2.0 (https://www.apache.org/licenses/LICENSE-2.0.txt) | |
| ## id : 729edcf0-c5d4-41cd-a977-541f4399952f | |
| ## created-on : 2025-02-07T17:36:39+01:00 | |
| ## managed-by : https://github.com/dacr/code-examples-manager | |
| ## run-with : nix eval --file $file | |
| #### run-with : nix-instantiate --eval $file | |
| let | |
| list1 = [1 [42 3] 4]; | |
| in with builtins; { | |
| look_for_42_1 = (head (tail list1)) ; | |
| look_for_42_2 = (elemAt (elemAt list1 1) 0) ; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment