
\documentclass[portuges,a4paper]{article}
\usepackage{babel}
\usepackage[mathletters]{ucs}
\usepackage[utf8x]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{fancyvrb}
%\usepackage{t1enc}
%\usepackage{jjaulas}
\usepackage{graphicx}
\usepackage{fancyvrb}
\RequirePackage[a4paper,top=2cm,left=2cm,right=2cm,bottom=1.5cm,nohead,nofoot]{geometry}
\parindent 0pt
\parskip 3pt
\fvset{fontsize=\small, numbers=left, frame=leftline, numberblanklines=false}

\newcounter{quest}
%\def\theenumi{\alpha{enumi}}
\newenvironment{questao}[2][]{

\def\theenumi{\alph{enumi})}
   \addtocounter{quest}{1}{\bf Quest\~ao \thequest\ (#2)}
 \marginpar{#1}
 }{

\addvspace{2mm}\mbox{}\hrule\mbox{}

}

\newenvironment{exame}[3]{\noindent\fbox{\begin{minipage}{\textwidth}\begin{center}
{\Huge #1 \\ \huge #2 \\ \large #3\\}
\end{center}\end{minipage}} \mbox{}\\}{}

\newcommand{\exametitle}[3]{\noindent\fbox{\begin{minipage}{\textwidth}\begin{center}
{\Huge #1 \\ \huge #2 \\ \large #3\\}
\end{center}\end{minipage}} \mbox{}\\}

\newif\iftth
\begin{document}
\exametitle{media}{jj\mbox{}}{\today}

\iftth
\begin{html}
<div style="float: left; width: 50%;">\end{html}
\fi
\subsection*{Question}
Considere o seguinte conjunto de classificações de uma turma:\\
notas do teste:\\
  \texttt{ A1 = 19.06   10.67   11.06   16.32}

notas finais:\\
  \texttt{ A2 = 9   10   6   9}

\begin{enumerate}
\item Qual a média das notas do teste turma?
\item Qual a média das notas finais?
\item Qual a moda das notas finais?
\end{enumerate}
\hrule
Considere o seguinte resultado de lançamento de dados do poker:\\
  \texttt{ A1 = rei   ás   ás   valete   rei   9   9   rei   valete   9   ás   ás   10   ás   ás}

\begin{enumerate}
\item Qual a moda das notas finais?
\end{enumerate}
\iftth
\begin{html}</div>
<div style="float: right; width: 50%;">
\end{html}
\fi

\iftth
\begin{html}<a href="#" onclick="toggle_visibility('sugestion');" >\end{html}
\fi
\subsection*{Sugestion}
\iftth
\begin{html}</a><div style="display:none;" id="sugestion">\end{html}
\fi

\iftth
\begin{html}</div>\end{html}
\fi

\iftth
\begin{html}<a href="#" onclick="toggle_visibility('resolution');" >\end{html}
\fi
\subsection*{Resolution}
\iftth
\begin{html}</a><div style="display:none;" id="resolution">\end{html}
\fi
\begin{enumerate}
\item 14.2775
\item 8.5
\item 9
\end{enumerate}
\hrule
\begin{enumerate}
\item "ás"
\end{enumerate}
\iftth
\begin{html}</div>\end{html}
\fi

\iftth
\begin{html}<a href="#" onclick="toggle_visibility('result');" >\end{html}
\fi
\subsection*{Result}
\iftth
\begin{html}</a><div style="display:none;" id="result">\end{html}
\fi

\iftth
\begin{html}</div>\end{html}
\fi

\subsection*{Obs}
\begin{Verbatim}
DEBUG:
n  amostra0[10] = num_sample_gen(10, 4, 20, 1);
   media0       = media_from_prev_sample()  ;

--   A0 = 4 18.6 7 7.7 16.8 11.4 4.6 9.1 7.9 18.1 --   M0 = 10.52

n  amostra1[4]  = num_sample_gen(4, 4, 20, 2);
   media1       = media_from_prev_sample()  ;

--   A1 = 19.06 10.67 11.06 16.32 --   M1 = 14.2775

n  amostra2[4] = num_sample_gen(4, 4, 20, 0);
   media2      = media_from_prev_sample()  ;
   moda2       = moda_from_prev_sample()  ;

--   A0 = 9 10 6 9 --   M0 = 8.5 --   Mo2 = 9

n  amostra3[15] = enum_sample_gen(15, "ás", "dama", "valete", "rei", 10, 9 );
   moda3       = moda_from_prev_sample()  ;

--   A3 = rei ás ás valete rei 9 9 rei valete 9 ás ás 10 ás ás --   Mo3 = "ás"
\end{Verbatim}



\iftth
\begin{html}<br><br><br><br></div>\end{html}
\fi


\end{document}
