You are on page 1of 5

1 i mport import 2 import 3 1 public 0 classM 1 public 1 staticvoid{ 1 new 2 u staticclass{ 15 1 int 8 1 int 9 2 public 7 u 2 this 8 n .

sew 2 try 9 { 3 n int this) . " I g ; 3 new this . 3 catch 2 3 ) this . " n u b a r e p s S" o r e 3 catch 4 this 5 3 . b g e . ( i r p o r n rE t 3 void 9 { 4 boolean 0 t p rue; 4 while 1 { try{ 4 4 this 3 , . e v o m [ " t his [encima][sobre]" r) . " i e g a l m i o v p s a e // a rm i 4 this if ( ) " i t c a _ . v o e ) m r 4 if 5this ( ) . " _ ) 4 else } 7 { 5 else 0 ifthis ( _ i t c a . " ) ) 5 if 1this ( ) . " _ ) 5 else } 3 { 5 else 6 5 t p 7 his. e 5 catch ( A catch( 2 6 this 6 g x e . . e r i ( p n r a nW t 6 false 4 ; 7 boolean 2 7 this 3 . v 7 return 4 false; 8 return 4 this. 9 void 4 v S ( n o t c A d i l a 9 int 5 9 int 8 i 9 j int new 1 1 t 0 ry { 1 while ( o T e r M s a h k t . n e switch( 1 1 case 5 0 1 break 0 ;

0 1 m 3

p ;

c e

a e

x n

case 1 9 0 1 break ; 1 case 2 1 break; 1 1 case 6 1 break; 1 1 default 9 1 : 1 if 4 2) " { l a s(action.equals( ) 1 t 2 his. 1 else 6 2 } if thrownew" 1 + I 1 else 8 2 if thrownew" 1 + r a p s o d m e D i s a 1 else 0 3 if) [ " + ] > this. 1 this. 1 o c _ m = this. 1 _ 1 t 3 his. _ 1 else 5 3 { 1 t 3 hrownew) " + 7 3 } A < ; 1 E 1 catch 3} ( N 1 throw 9 3 new s" o l n e + A R EO R 1 catch 4} n t n ( e S o m N e { l E uh c 1 throw 4 new c i " c a A + m r o f O F R : " O MT A 1 v 4oidv 1 i 5 nt 1 f 5 orint ( 1 while 5 true ( ) 1 i 5 fs i // (k == i) { 1 if 7 5{ 1 break 5 / ; / i 1 i f e / t i s { s / o l 1 else 6 { 1 break 5 6 / ; e s t / s o this. 168 p 1 v 7oid 1 v 8oid p 1 v 9oid 1 t 9 his); . " p e y B " 2 v 0oid p 2 t 0 his. p 2 v 1oid p 2 t 1 his" . + p A 2oida v s e m 2 t his" . + p 23 static 6 classb 2 p 3rivatefinalintm 2 p 3rivateb 2 public 4 int

i 2 4 fthis. x a m 2 this 7 n 4 . bewb 2 for 8 4 int ( thisn 2 . bewb 2 else 5} { 2 throw 5 new+ " t E his); . " m. " 2 public 6 voidi m ntint i,{ 2 i 6 fthis ( .eslegal(i,j)) { this.delynkDOWN(i); 264 this.desapilarde(i); 265 this.desapilarde(j); 266 this. 267 l 2 public 7 voidi m ntint i,{ 2 i 7 fthis ( . l s e 2 this 9 i 7 ) . this ( l e N d W O y Dk . s e dn 2 this 1 t 8 . n y l his. t e g 2 public 9 voidi a ntint i,{ 2 i 9 fthis ( . l s e e g l a i 2 this 3 .delynkDOWN(i); 9 this.desapilarde(j); 294 this. 295 l 3 public 0 voidi a ntint i,{ 3 i 0 fthis ( . l s e e 3 this 7 .delynkDOWN(i); 0 thist 308 . n y l his. t e g 3 p 1rivatevoidd int{ 3 if 8 1this ( . v a h 3 t 1 hist . i n his. t e g O D N W 3 p 2rivatebooleang int ) i 3 r 2 eturnthis > .numbloques()); 0 3 private 3 booleane intint i,{ 3eturnthis r ( t . o g his. g 3 private 4 booleanintint i,{ 3 r 4 eturnthis ( . this. 3 p 5rivateinti g nt 3 i 5 fthis ( . { returnthist 3 . g his. g 3 else 6} { 3 return 3 p 7rivateintg int o B t e 3 i 7 fthis ( . D e v a h returnthisthis 2 7 3 . .getDOWN(i)); 3 else 7} { 3 return 3 p 8rivatevoidd int{ 3 i 9 nt 3 w 9 hilethis ( . { 3 t 9 his. g 3 this if ( . U e v a h

i =

g 7

h 9

this 3 = j 5 9 . g 3 this 9 . i 3 t 9 his. i n this. 3 l 3 else 9 { 4 t 0 his. i n this. 4 i 4 p 1rivatevoidintint i,{ 4 t 1 his. t e s 4 t 1 his. s 4 p 2rivateint{ 4 t 3 ry { 4 return 1 3 this. b 4 catch 3} returnnewb 4 4 ublicint p 4eturnthis. r o l b 4 rivatevoidint{ p 4 t 5 his. n i ) ( e u t q g o l b 4 p 5ublicbooleani h nt{ 4 r 5 eturnthis. a h ) i ( e u q t g o l b 4 p 6ublicinti e g nt{ 4 r 6 eturnthis. e g ) i ( u q t g o l b 4 private 7 voidintint i,v 4 t 7 his. g 4 p 8rivatevoidi int{ 4 t 8 his. 4 p 9ublicbooleani h nt{ 4 r 9 eturnthis. g 5 p 0ublicintg int{ 5 r 0 eturnthis. e g ) i ( u q t g o l b 5 private 1 voids intint i,v 5 t 1 his ) . . i t e ( g u q bo l 52 static 5 classb 5 p 2rivatefinalint noBLOQUES = -1; 5 p 3rivateint 5 p 3rivateint 5 public 4 b 5 t 4 his. i 5 t 4 his. i 5 ublicvoidi p 5 t histhis . = p u . n 5 ublicbooleanh p 5eturnthisthis r . = ! p u . n 5 p 6ublicintg 5 r 6 eturnthis. ; p u 5 p 7ublicvoidintv 5 i 7 f( this. B o n 5 this 6 . 7 i

e 7 5 }lse { 5 this 8 7 . u 5 p 8ublicvoid 5 t 8 hist . = w o d his. n 5 p 9ublicboolean 5 r 9 eturnt ( hist . d his. n 5 p 9ublicintg 6 r 0 eturnthis.d own; 6 public 0 voidi s ntv 6 i 0 f( this. B o n 6 this 0 . 1 i 6 else 1} { this.down = value; 612 62 static 3 classA extendsE 6 private 2 staticfinallong ; L 1 6 p 2ublic 6 s 2uper U C " ( ; ) D O R P H E SN A 6 public 3 A 6 s 3uper( m 4 6 static 2 classextendsE 6 private 4 staticfinallong ; L 1 6 p 4ublicb 6 s 4uper U C " ( ; ) D O R P H E SN A 6 public 5 6 s 5uper( m

You might also like