This file contains 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
#!/usr/bin/env bash | |
ipynb_set_authors () { | |
local authors="[]" | |
local file="$1" | |
for author in "${@:2}"; do | |
authors="$(jq --arg author "$author" '. + [{"name": $author}]' <(echo "$authors"))" || return $? | |
done | |
jq_edit "$file" --argjson authors "$authors" '.metadata.authors = $authors' | |
} |
This file contains 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
#include <iostream> | |
// Ejemplo de contador binario usando listas enlazadas | |
template<typename T> | |
struct Node { | |
Node<T>* next; | |
T data; | |
Node(T data, Node<T>* next=nullptr): data(data), next(next) {} | |
}; |