is
. J) f. P: E' I M* G8 W* flocal links,rechts : integer;
/ ]& Y/ ?& R5 \% Zdo# a; b; X8 r7 E) i5 l4 D8 K
if @.standort.nf(1).nf(1).voll
* B% S: q+ O$ r and @.standort.nf(2).nf(1).voll
' z0 y5 F, P ]! k& l& L2 A and @.standort.nf(3).nf(1).voll0 k) n, p1 _* Y; _
then
5 G# h# H! ~1 |6 l7 q* g blockier_merker := TRUE;
; M4 ^' B7 u( P8 o0 n/ G* K( k else
# g2 K# _/ w( a if @.standort.nf(1).nf(1).leer5 @8 S/ P! y) D& ]
then
' @& c( O. L, {( B1 i# q- `+ k" F @.ziel := "ap4_C";
# E/ K* I0 u2 V* }; K& C @.umlagern(@.standort.nf(1));* H A$ T6 N! i+ U
else
* D& L5 x) k3 c3 t- h N4 v2 @ links := current.standort.stichE.AnzahlBEs + current.standort.stichD.AnzahlBEs
' n- V j! I+ M+ `. ?% D. s + current.standort.zuf_E.AnzahlBEs + current.standort.zuf_D.AnzahlBEs
8 q/ ^: R& y$ F$ d6 c + current.standort.ap4_E.AnzahlBEs + current.standort.ap4_D.AnzahlBEs;$ G4 k* ?& ~: ?$ B9 p
rechts := current.standort.stichB.AnzahlBEs + current.standort.stichA.AnzahlBEs - p+ |( Z4 J; U
+ current.standort.zuf_B.AnzahlBEs + current.standort.zuf_A.AnzahlBEs ( y1 L. j. j/ h$ Q& A
+ current.standort.ap4_B.AnzahlBEs + current.standort.ap4_A.AnzahlBEs;, Q X3 Y S- }4 O& q# A# {
if links > rechts / O! e. u+ y7 p5 Y
then1 h0 b" {- ^6 _1 [) `
if @.standort.nf(3).nf(1).leer) E3 H, z6 a5 s1 E# T2 K5 t5 g9 Y
then
* u+ D: T# p% R- Q! ? @.umlagern(@.standort.nf(3));
1 Y8 Q, \) \1 P& i else
( F8 N$ H" [; J F `& ~7 U7 u' H6 y if @.standort.nf(2).nf(1).leer
% k* @% L/ I `) G. j. l4 _ then$ x8 X5 U. l/ t
@.umlagern(@.standort.nf(2));
3 k3 ?7 [& d: @6 h, J else K( }, s+ x! E$ Z/ i6 a
@.umlagern(@.standort.nf(1));' d6 ?4 T2 N# F5 |/ d
end;
- n u* w3 g8 `! z+ l" `' C end;$ ?+ d9 P3 ?: L/ e8 W# L/ \2 M3 z/ O
else
0 A- j; {- Z: y K( R4 d' q if @.standort.nf(2).nf(1).leer2 P& I+ C, X% K
then
4 X+ [% p6 ]8 M$ L: t! q$ f. p6 E @.umlagern(@.standort.nf(2)); * `3 z* P* i2 M$ {
else
) j) c% Z% ^. T if @.standort.nf(3).nf(1).leer
1 K5 s# }) j$ U$ ?$ |: w then
& m* y' C7 \1 h( x @.umlagern(@.standort.nf(3));6 H- M1 }% a$ n! X. n
else6 E, l, V: \0 X# S
@.umlagern(@.standort.nf(1));9 m' [5 F% [$ a
end;
/ Z9 G7 j2 a# y9 N' p- k end;6 L, u1 Z5 N0 ?' @
end; * ]3 {0 |7 l, y/ E: v M& O$ F6 e- k
end;* M- ^1 N* m. x( }3 b" [
end;, ]+ b3 V/ v2 |1 {0 G1 M' N0 {
if ?.leer. S8 n) ?1 b1 c! X
then
9 l; V# d0 D) u2 c" j5 i blockier_merker := false;/ U3 x! [' T) q S
end;" @/ l H |8 J1 h0 N' w" L. v, `, \
end;
% q. ?4 {' o4 Z" j% i大家帮忙看看上面的程序是怎样实现分配的,好像用了一个遗传算法的。 |