topnush
I can draw a Venn diagram with:
```
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\def\radius{2cm}
\def\mycolorbox#1{\textcolor{#1}{\rule{2ex}{2ex}}}
\colorlet{colori}{blue!70}
\colorlet{colorii}{red!70}
\coordinate (ceni);
\coordinate[xshift=\radius] (cenii);
\draw[fill=colori,fill opacity=0.5] (ceni) circle (\radius);
\draw[fill=colorii,fill opacity=0.5] (cenii) circle (\radius);
% Label A
\node[above] at ([yshift=\radius]ceni) {$A$};
% Label B
\node[above] at ([yshift=\radius]cenii) {$B$};
\draw ([xshift=-20pt,yshift=20pt]current bounding box.north west)
rectangle ([xshift=20pt,yshift=-20pt]current bounding box.south east);
\end{tikzpicture}
\end{document}
```

I would like to randomly scatter the letters a to z in the Venn diagram (one copy of each letter). How can one do that?
Top Answer
samcarter
As a quick solution you could randomly distribute the letters in an indescribed rectangle:
```
\documentclass{standalone}
\usepackage{tikz}
\pgfmathsetseed{\number\pdfrandomseed}
\begin{document}
\begin{tikzpicture}
\def\radius{2cm}
\def\mycolorbox#1{\textcolor{#1}{\rule{2ex}{2ex}}}
\colorlet{colori}{blue!70}
\colorlet{colorii}{red!70}
\coordinate (ceni);
\coordinate[xshift=\radius] (cenii);
\draw[fill=colori,fill opacity=0.5] (ceni) circle (\radius);
\draw[fill=colorii,fill opacity=0.5] (cenii) circle (\radius);
% Label A
\node[above] at ([yshift=\radius]ceni) {$A$};
% Label B
\node[above] at ([yshift=\radius]cenii) {$B$};
\draw ([xshift=-20pt,yshift=20pt]current bounding box.north west)
rectangle ([xshift=20pt,yshift=-20pt]current bounding box.south east);
\foreach \macro in {a,...,z}{
\pgfmathsetmacro\ranx{4.8*random()-1.4}
\pgfmathsetmacro\rany{2.8*random()-1.4}
\node at (\ranx,\rany) {\macro};
}
\end{tikzpicture}
\end{document}
```
