is) \! M, U, k9 I7 c0 B( W
local links,rechts : integer;3 K% C2 A1 y8 x. F3 ^& b+ p# Y
do ^# ?, h- i8 r1 R
if @.standort.nf(1).nf(1).voll
. P; b' h! A5 `& c and @.standort.nf(2).nf(1).voll* J8 p H& }+ E; K O+ N) z
and @.standort.nf(3).nf(1).voll& I% i9 x: S' L5 F r; k
then
& Z6 [# n9 {. D4 o blockier_merker := TRUE;* I3 h# X s T$ @! b1 h7 z
else3 U% u: y0 w- e: c/ J# R
if @.standort.nf(1).nf(1).leer
2 Z5 x; i8 f, o& l( } then
L A6 A$ e* ] @.ziel := "ap4_C";
. L- s% M2 v, m' y+ ~2 z* o @.umlagern(@.standort.nf(1));
+ E) j. R! R2 e i# c! R else
, b5 x* M2 T5 m6 K3 t7 f# [ links := current.standort.stichE.AnzahlBEs + current.standort.stichD.AnzahlBEs
( N1 |( {% K `9 ^; } + current.standort.zuf_E.AnzahlBEs + current.standort.zuf_D.AnzahlBEs
* y( c( U6 z- ~ + current.standort.ap4_E.AnzahlBEs + current.standort.ap4_D.AnzahlBEs;% \% Q; \& E% ]2 R! G) Z1 U" D! H5 W
rechts := current.standort.stichB.AnzahlBEs + current.standort.stichA.AnzahlBEs + {; ^ X: h% _9 n3 o8 K0 X7 Z
+ current.standort.zuf_B.AnzahlBEs + current.standort.zuf_A.AnzahlBEs
% R7 |8 a6 c% Q0 H: `/ N + current.standort.ap4_B.AnzahlBEs + current.standort.ap4_A.AnzahlBEs;
* B( G' o) C: [" b H1 Q5 X4 E if links > rechts
4 W9 C, ? j0 L f q- w then% Z) B) S; U! K& J8 e5 |
if @.standort.nf(3).nf(1).leer$ Z# u1 H) ]0 V, q$ U
then7 ]0 ~0 a2 W2 r# ^% ]. R
@.umlagern(@.standort.nf(3)); 5 Y$ d8 t6 I- S; P6 q# @7 k$ F3 o
else
# _& |; p. c( @: |% h# g- j if @.standort.nf(2).nf(1).leer
$ V8 y) o1 f2 U3 w then p O+ W& a* M% x% i" g
@.umlagern(@.standort.nf(2));. J r5 W" ^. T$ S7 Z+ {3 q* Q
else+ c, R# }8 i5 ]' W( Q' F6 B( Y
@.umlagern(@.standort.nf(1));
# L: c! T1 S. Z end;
1 x# m8 G$ G) n/ y' ~7 X7 W. n end;& ~& j2 U% }. W' a$ f! b J
else 6 I+ B& a7 M( {! R( n t
if @.standort.nf(2).nf(1).leer
- h$ G' J2 C0 A. s/ x' `: |" \ then
. Z3 ?' L+ C! t/ y+ V. b4 _* W @.umlagern(@.standort.nf(2));
' z3 G/ H8 V3 A- {( V- k else
% l' r5 Q8 ]$ O if @.standort.nf(3).nf(1).leer
- q- @/ |3 r1 }7 W& D then4 C% h3 G3 b3 k* _2 F
@.umlagern(@.standort.nf(3));
9 I3 ^8 O# k: X3 D, ~ else. i5 N& K2 x6 d$ K- _5 y
@.umlagern(@.standort.nf(1));
0 F( G; o G" \$ h f4 c end;
) ~+ p& e/ T: Y9 o end;& r# R, v! A h. Y D1 ~- ~' \
end; ( q8 P9 z" W1 f
end;" u' s' L0 v0 H( p. B# v. F
end;, \: r6 ~% ^3 ^" q7 P0 e
if ?.leer
. q* _, O* C* N0 hthen
+ k5 O. F& l9 w; ~6 g2 H8 { blockier_merker := false;
) ?9 f. o+ b9 O7 Z; a' bend;
* l$ |: E, e3 z1 e% m1 |end;
9 l B, U# s* X大家帮忙看看上面的程序是怎样实现分配的,好像用了一个遗传算法的。 |