Está en la página 1de 2

| barrel boxes pack truck|

pack:= Pack new initialize.


pack tipoCarga: 'Materiales de construccion'.
pack cantidadcajas: 10.
pack estructura: 50.
pack pesocajas: 3.

Transcript cr; show: 'Estas son las caracteristicas del packing: ', pack
asString;cr.
Transcript cr ; show: 'El peso del packing es de: '.
Transcript show: pack peso;cr.

barrel:= Barrel new initialize.


barrel capacidad: 80.
barrel densidad: 4.
Transcript cr;show: 'Estas son las caracteristicas del bidon: ', barrel asString;cr.
Transcript cr;show: 'El peso del bidon es de '.
Transcript show: barrel peso;cr.

boxes:= Boxes new initialize.


boxes peso: 50.
Transcript cr;show: 'Estas son las caracteristicas de la caja suelta: ', boxes
asString ;cr.

truck := Truckk new initialize.


truck estado: 'Disponible'.
truck capacidad: 500.
Transcript cr; show: 'Estas son las caracteritsticas del camion: ', truck
asString;cr.

Transcript clear.
truck cargar: boxes.
Transcript cr;show: 'El peso del camion es: '.
Transcript show: truck peso;cr.

truck cargar: pack.


Transcript cr;show: 'El peso del camion es: '.
Transcript show: truck peso;cr.

truck cargar: barrel.


Transcript cr;show: 'El peso del camion es: '.
Transcript show: truck peso;cr.

truck bajar: boxes.


Transcript cr;show: 'El peso del camion es: '.
Transcript show: truck peso;cr.

Transcript show: 'Conocer total de cargas.';cr.


Transcript show: truck conocer.

Transcript clear.
Transcript show: 'Listado cargas ordenadas por peso.';cr.
Transcript show: truck ordenadas.

Transcript show: 'Esta disponible para partir?';cr.


Transcript show: truck listoParaSalir .

También podría gustarte