|
|
@@ -59,6 +59,16 @@
|
|
|
\end{problema}
|
|
|
|
|
|
\begin{problema}{listoParaCosecharS}{s: Sistema}{\bool}
|
|
|
+ \asegura { res == ( contarCultivosListos/contarCultivos(s) \geq 0.9 ) }
|
|
|
+
|
|
|
+ \begin{aux}{contarCultivos}{s: Sistema}{\ent}
|
|
|
+ { |[ 1 | \newline i \leftarrow [0..prs(dimensiones(campo(s))) \newline j \leftarrow [0..snd(dimensiones(campo(s))), \newline contenido(campo(s),i,j)==Cultivo) ]| }
|
|
|
+ \end{aux}
|
|
|
+ \begin{aux}{contarCultivosListos}{s: Sistema}{\ent}
|
|
|
+ { |[ 1 | \newline i \leftarrow [0..prs(dimensiones(campo(s))) \newline j \leftarrow [0..snd(dimensiones(campo(s))), \newline contenido(campo(s),i,j)==Cultivo \wedge
|
|
|
+ estadoDelCultivo(s,i,j) == ListoParaCosechar ) ]| }
|
|
|
+ \end{aux}
|
|
|
+
|
|
|
\end{problema}
|
|
|
|
|
|
\begin{problema}{aterrizarYCargarBateriaS}{s: Sistema, b: \ent}{}
|