tubin o tubito. AUX ToBin
Página 1 de 1. • Compartir •
tubin o tubito. AUX ToBin
aux ToBin (l:[etiqueta], t:Tema) :[Int] =
[β( ( Existe e <- etiquetas(t) )e == l[i])| i <-[0...|l|) ]
aux <bin(b1,b2:[Int]):Bool =
if ( (¥ h <- b1 ) h == 1 o h == 0) y ( (¥ h <- b2 ) h == 1 o h == 0 )
then (ToDecimal (b1) < ToDecimal (b2))
aux <bin(b1,b2:[Int]):Bool =
if ( (¥ h <- b1 ) h == 1 o h == 0) y ( (¥ h <- b2 ) h == 1 o h == 0 )
then (ToDecimal (b1) == ToDecimal (b2))
aux ToDecimal (b:[Int]) :Int =
if (¥ h <- b ) h == 1 o h == 0
then ∑[ b[i]*(pot(2,i))| i <- [0...|b|)]
[β( ( Existe e <- etiquetas(t) )e == l[i])| i <-[0...|l|) ]
aux <bin(b1,b2:[Int]):Bool =
if ( (¥ h <- b1 ) h == 1 o h == 0) y ( (¥ h <- b2 ) h == 1 o h == 0 )
then (ToDecimal (b1) < ToDecimal (b2))
aux <bin(b1,b2:[Int]):Bool =
if ( (¥ h <- b1 ) h == 1 o h == 0) y ( (¥ h <- b2 ) h == 1 o h == 0 )
then (ToDecimal (b1) == ToDecimal (b2))
aux ToDecimal (b:[Int]) :Int =
if (¥ h <- b ) h == 1 o h == 0
then ∑[ b[i]*(pot(2,i))| i <- [0...|b|)]

mariano!!- Admin
- Mensajes: 31
Fecha de inscripción: 04/09/2008
Edad: 21

Permiso de este foro:
No puedes responder a temas en este foro.





