\documentclass[a4paper,italiano]{article}
\usepackage[shuffle,xyz,pointsonright,solutions]{esami}%%%%% TEMA
        \usepackage{fixltx2e}
        \usepackage[T1]{fontenc}
        \usepackage[utf8,latin1]{inputenc}
        \usepackage{lmodern,textcomp}
%        \usepackage{pst-pdf}

% +=============================+
% |         DEFINITIONS         |
% +=============================+

\def\examname{Scritto di Fisica Generale  per Ingegneria Edile (N41)}
\def\numcompiti{5}%%% The number of the versions
\date{2020/06/15}%%% THE DATE IN THE FORMAT YYYY/M/D or D/M/YYYY
\def\Data{\longdate}%%% or \shortdate: the date in the heading\setcounter{1}{1}
\def\cartella{Esercizi}
\usepackage{babel}

\begin{document}
\testversioni
\pagestyle{esame}

\whiledo{\thevers<\numcompiti}{\stepvers
% +=============================+
% |       THE SEED              |
% +=============================+

%\FPeval\seme{round((\thenomefile+(3*\thevers)):0)}
%%% OR SOME OTHER LIKE
\FPeval\seme{round(\thenomefile*(\thevers)+1-trunc(\thenomefile*(\thevers)/(2^31-1):0)*(2^31-1):0)}
%\FPeval\seme{round(1+abs(\thenomefile/(\thevers)+sin(\thevers)*(\thevers)^(2)):0)}

\randomi=\seme

\permuta
% +=============================+
% |  STUFF DEFINED IN CFG FILE  |
% +=============================+
\testa%%% the heading
%\istruzionii%%%  some instructions

\begin{esdb}{meca}
	\selectrandomlyn{1}{Esercizi/meccanica1}
\end{esdb}	
\begin{esdb}{mecb}
	\selectrandomlyn{1}{Esercizi/meccanica2}
\end{esdb}	
\begin{esdb}{termo}
		\selectrandomlyn{1}{Esercizi/calorimetria1}
% 	\selectrandomlyn{1}{Esercizi/fluidi1}
\end{esdb}
%\esercizi{meccanica1,meccanica2,calorimetria1}
\closevers
\newpage                                                       
\setcounter{page}{1} %%% dvi
}

\end{document}
