Quantcast
Channel: Rectangular table with consecutive integers using foreach - TeX - LaTeX Stack Exchange
Viewing all articles
Browse latest Browse all 4

Answer by Ignasi for Rectangular table with consecutive integers using foreach

$
0
0
\documentclass[tikz, border=2mm]{standalone}\begin{document}\begin{tikzpicture}\foreach \i in {0,1,2,...,8}{  \foreach \j [evaluate=\j as \num using int(9*(4-\j)+\i+1)] in {1,2,3,4}    \node[fill=blue!15, minimum size=1cm, draw] at (\i,\j) {\num};}\end{tikzpicture}\end{document}

enter image description here


Viewing all articles
Browse latest Browse all 4

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>