Digital Mark λ ☕️ 🕹 🙄<p>Doing some table generation in awk, and is there an easier way to do "all fields n to NF" than this?</p><p>function combine(combn, combs) {<br> for (; combn<=NF; ++combn) {<br> combs=combs "\t" $(combn)<br> }<br> return combs<br>}</p><p>I could use printf on the fragments, but the annoyance is that loop, instead of<br>(string-join (cddr fields) "\t")<br>or whatever.</p><p><a href="https://appdot.net/tags/awk" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>awk</span></a> <a href="https://appdot.net/tags/unix" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>unix</span></a> <a href="https://appdot.net/tags/codegolf" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>codegolf</span></a></p>