Last active
July 8, 2022 09:44
-
-
Save Akasurde/8592505a74ebe1fbc49dde9449b123c6 to your computer and use it in GitHub Desktop.
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
- name: Remove nth element from the list by value | |
debug: | |
msg: | | |
{% set _ = my_list.remove(value) %} | |
{{ my_list }} | |
vars: | |
my_list: [1, 2, 3, 4, 5, 6] | |
value: 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment