Advertisement
Guest User

Untitled

a guest
Sep 26th, 2016
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.28 KB | None | 0 0
  1. massiv = array [1..9000] of word;
  2. mkts = array [0..3, 1..6, 1..16] of SmallInt;
  3. mdl = array [0..3, 1..6, 1..15] of SmallInt;
  4. msh = array[1..392] of SmallInt;
  5.  
  6. TPmkts = ^mkts;
  7. TPmdl = ^mdl;
  8. TPmsh = ^msh;
  9.  
  10. Pkts: array[1..4, 1..2] of TPmkts = ( (nil, nil),
  11. (nil, nil), (nil, nil), (nil, nil) );
  12. Pdl: array[1..4, 1..2] of TPmdl = ( (nil, nil),
  13. (nil, nil), (nil, nil), (nil, nil) );
  14. Psh: array[1..4, 1..2] of TPmsh = ( (nil, nil),
  15. (nil, nil), (nil, nil), (nil, nil) );
  16. begin
  17. ...
  18. New(Pdl[1, 1]);
  19. New(Pozu[1, 1]);
  20. Pkts[1, 1]:= @Psh[1, 1]^[9];
  21.  
  22. for KCO:=0 to 3 do
  23. for Tip:=1 to 6 do
  24. begin
  25. CCO:=1;
  26. repeat
  27. if PKTS[1, 1]^[KCO, Tip, CCO] = (-1) then
  28. PDL[1, 1]^[KCO, Tip, CCO]:= 0
  29. else
  30. begin
  31. i:=CCO;
  32. repeat Inc(i);
  33. until (PKTS[1, 1]^[KCO, Tip, i] <> (-1));
  34. PDL[1, 1]^[KCO, Tip, CCO]:= PKTS[1, 1]^[KCO, Tip, i] -
  35. PKTS[1, 1]^[KCO, Tip, CCO];
  36. case Tip of
  37. 2,5 : PDL[1, 1]^[KCO, Tip, CCO]:=
  38. PDL[1, 1]^[KCO, Tip, CCO]*5;
  39. 3,4,6: PDL[1, 1]^[KCO, Tip, CCO]:=
  40. PDL[1, 1]^[KCO, Tip, CCO]*8;
  41. end;
  42. end;
  43. Inc(CCO);
  44. until CCO=16;
  45. end;
  46. ..
  47. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement