1. Pascal / Говнокод #364

    +29

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    if (Name = PictSection) then
      begin
        if frVariables['SECTION'] <> null then
        if frVariables['SEC_FIRM_ID'] <> null then
                       ;
        exit;
      end;

    Нах вообще проверка...

    guest, 11 Января 2009

    Комментарии (1)
  2. Pascal / Говнокод #361

    +20.3

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    if TimeToStr(Now) = TimeToStr(Now) then
     begin
      ShowMessage(TimeToStr(Now));
        end
       else
        ShowMessage(TimeToStr(Now))
       end;

    часеги

    guest, 11 Января 2009

    Комментарии (8)
  3. Pascal / Говнокод #319

    +30

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    29. 29
    30. 30
    31. 31
    32. 32
    33. 33
    34. 34
    35. 35
    36. 36
    37. 37
    38. 38
    39. 39
    40. 40
    41. 41
    42. 42
    43. 43
    44. 44
    45. 45
    46. 46
    47. 47
    48. 48
    49. 49
    50. 50
    51. 51
    52. 52
    53. 53
    54. 54
    55. 55
    56. 56
    57. 57
    58. 58
    59. 59
    60. 60
    61. 61
    62. 62
    63. 63
    64. 64
    65. 65
    66. 66
    67. 67
    68. 68
    69. 69
    70. 70
    71. 71
    72. 72
    73. 73
    74. 74
    75. 75
    76. 76
    77. 77
    78. 78
    79. 79
    80. 80
    81. 81
    82. 82
    83. 83
    84. 84
    85. 85
    86. 86
    87. 87
    88. 88
    89. 89
    for i := 0 to high(vParagsChanges) do
        begin
          if vParNumIn < vParagsChanges[i].ParNo1 then
          begin
            inc(vParNumOut, vParagsChanges[i].ParNo1 - vParNumIn);
            vParNumIn := vParagsChanges[i].ParNo1;
          end;
    
          if i < high(vParagsChanges) then
            if (vParagsChanges[i].ParNo1+vParagsChanges[i].Range=vParagsChanges[i+1].ParNo1) and
            ((vParagsChanges[i].Kind=ckDelete) and (vParagsChanges[i+1].Kind=ckAdd)) then
              {if vParagsChanges[i].Range = vParagsChanges[i+1].Range then} 
              begin
                vUnitedPars := min(vParagsChanges[i].Range, vParagsChanges[i+1].Range);
                if vParagsChanges[i+1].Range >= vUnitedPars then
                  vParagsChanges[i+1].Range := vParagsChanges[i+1].Range - vUnitedPars;
                if vParagsChanges[i].Range >= vUnitedPars then
                  vParagsChanges[i].Range := vParagsChanges[i].Range - vUnitedPars;
                for j := 0 to vUnitedPars-1 do 
                begin
                  FParsHL[vParNumIn+vInsertedCount1+j].Kind := pkReplaced;
                  vTagsInfoEx := GetTagsInfo(Editor1.Parag(vParNumIn+vInsertedCount1+j).Str); 
                  FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups := GetViewGroupsByChangeItems(vTagsInfoEx.TagKinds);
                  vTagsInfoEx := GetTagsInfo(Editor2.Parag(vParNumIn+vInsertedCount1+j).Str);
                  FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups := FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups + GetViewGroupsByChangeItems(vTagsInfoEx.TagKinds);
                  if vParagsChanges[i].InCard then 
                    FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups := FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups + [vgCard]
                  else
                    FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups := FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups + [vgText];
                end;
                inc(vParNumIn, vUnitedPars);
                inc(vParNumOut, vUnitedPars);
              end;
    
          case vParagsChanges[i].Kind of
            ckAdd: begin
              for j := 0 to vParagsChanges[i].Range-1 do
              begin
                vTmpParag := TRTFParag.Create(nil, False, False, raLeft{raRight});
                FEditor1.InsPar(vParNumIn+vInsertedCount1+j, vTmpParag, false);
                FParsHL[vParNumIn+vInsertedCount1+j].Kind := pkAdded;
                vTagsInfoEx := GetTagsInfo(Editor2.Parag(vParNumOut+vInsertedCount2+j).Str); 
                if vParagsChanges[i].InCard then 
                  FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups := GetViewGroupsByChangeItems(vTagsInfoEx.TagKinds) + [vgCard]
                else 
                  FParsHL[vParNumIn+vInsertedCount1+j].ViewGroups := GetViewGroupsByChangeItems(vTagsInfoEx.TagKinds) + [vgText];
              end;
              inc(vInsertedCount1, vParagsChanges[i].Range);
              inc(vParNumOut, vParagsChanges[i].Range);
            end;
            ckDelete: begin
              for j := 0 to vParagsChanges[i].Range-1 do
              begin
                vTmpParag := TRTFParag.Create(nil, False, False, raLeft);
                FEditor2.InsPar(vParNumOut+vInsertedCount2+j, vTmpParag, false);
                FParsHL[vParNumOut+vInsertedCount2+j].Kind := pkDeleted;
                vTagsInfoEx := GetTagsInfo(Editor1.Parag(vParNumIn+vInsertedCount1+j).Str); 
                if vParagsChanges[i].InCard then 
                  FParsHL[vParNumOut+vInsertedCount2+j].ViewGroups := GetViewGroupsByChangeItems(vTagsInfoEx.TagKinds) + [vgCard]
                else 
                  FParsHL[vParNumOut+vInsertedCount2+j].ViewGroups := GetViewGroupsByChangeItems(vTagsInfoEx.TagKinds) + [vgText];
              end;
              inc(vInsertedCount2, vParagsChanges[i].Range);
              inc(vParNumIn, vParagsChanges[i].Range);
            end;
            ckModify: begin 
              if (ciAlignment in vParagsChanges[i].ChangedItems) and (vParagsChanges[i].StrChanges = nil) then
                FParsHL[vParNumIn+vInsertedCount1].Kind := pkAlignment
              else
                FParsHL[vParNumIn+vInsertedCount1].Kind := pkModified;
    
              FParsHL[vParNumIn+vInsertedCount1].Changes := GetViewChanges(vParagsChanges[i].StrChanges);
              FParsHL[vParNumIn+vInsertedCount1].ViewGroups := GetViewGroupsByChangeItems(vParagsChanges[i].ChangedItems);
              if vParagsChanges[i].InCard then 
                if (ciText in vParagsChanges[i].ChangedItems) or (ciAlignment in vParagsChanges[i].ChangedItems) then 
                begin 
                  FParsHL[vParNumIn+vInsertedCount1].ViewGroups := FParsHL[vParNumIn+vInsertedCount1].ViewGroups + [vgCard];
                  FParsHL[vParNumIn+vInsertedCount1].ViewGroups := FParsHL[vParNumIn+vInsertedCount1].ViewGroups - [vgText, vgAlignment];
    
                  for j := 0 to high(FParsHL[vParNumIn+vInsertedCount1].Changes) do 
                    if FParsHL[vParNumIn+vInsertedCount1].Changes[j].ViewGroup = vgText then
                      FParsHL[vParNumIn+vInsertedCount1].Changes[j].ViewGroup := vgCard;
                end;
    
              inc(vParNumIn, 1);
              inc(vParNumOut, 1);
            end;
          end;
        end;

    Такой г****код возник не за 1 день. Голову пришлось поломать основательно :))
    Комментарии убраны, дабы не портить удовольствие от прочтения.

    guest, 31 Декабря 2008

    Комментарии (2)
  4. Pascal / Говнокод #272

    −21

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    // Как Было 
      if even then 
        begin
         if (GameAreaForm.Area.ColCount mod 2 = 0) then isstandart:=true
         else isstandart:=false; 
        end
      else
         begin
           if (GameAreaForm.Area.ColCount mod 2 = 0) then isstandart:=false
           else isstandart:=true;
         end;
    
    // Как стало
    if (even) then isstandart:=not(GameAreaForm.Area.ColCount mod 2 = 0);
    else isstandart:=(GameAreaForm.Area.ColCount mod 2 = 0);

    Сравните две части кода.
    Однако бывает :-)

    guest, 24 Декабря 2008

    Комментарии (26)
  5. Pascal / Говнокод #256

    −20.5

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    29. 29
    30. 30
    31. 31
    32. 32
    33. 33
    function find7(S:string):integer;
    var
    MyArray : TStringList;
    n,i,sum, Resultat : integer;
    MyInt : String;
    begin
    MyArray := TStringList.Create;
    Trim(S); n:= 0;
    while(Length(s)>0) do begin
    Trim(S);
    if(Pos(' ',S)=0) then begin
    MyArray.Insert(n,Copy(S,1,Length(S)));
    break;
    end else begin
      if(Copy(S,1,Pos(' ',S))=' ') then begin
      Delete(S,1,(Pos(' ',S)));
      end else begin
        MyArray.Insert(n,Copy(S,1,Pos(' ',S)));
        Delete(S,1,(Pos(' ',S)));
        n:=n+1;
        end;
    end;
    end;
      Resultat := 0;
      for i := 0 to MyArray.Count-1 do begin
        MyInt := MyArray.Strings[i]; Sum := 0;
        for n := 1 to Length(MyInt) do begin
          if(MyInt[n]='7') then Sum := Sum + 1;
        end;
        if(Sum>=2) then Resultat := Resultat + 1;
      end;
      Result := Resultat;
    end;

    Жуть...

    guest, 24 Декабря 2008

    Комментарии (7)
  6. Pascal / Говнокод #243

    −29.2

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    for i:=1 to n do
    begin
        j:=i;
        a:=b*exp((j-1)*ln(r));
    end;

    Задание геометрической прогрессии. Из решения школьной задачки.

    guest, 22 Декабря 2008

    Комментарии (9)
  7. Pascal / Говнокод #234

    −186.9

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    29. 29
    30. 30
    31. 31
    32. 32
    33. 33
    34. 34
    35. 35
    36. 36
    37. 37
    38. 38
    39. 39
    40. 40
    41. 41
    42. 42
    43. 43
    44. 44
    45. 45
    46. 46
    47. 47
    48. 48
    49. 49
    50. 50
    51. 51
    52. 52
    53. 53
    54. 54
    55. 55
    56. 56
    57. 57
    58. 58
    59. 59
    60. 60
    61. 61
    62. 62
    63. 63
    64. 64
    65. 65
    for J1:=0 to Length(wArTypCoil[JJ])-1 do begin
          with wArTypCoil[JJ][J1] do begin
           with cTyp_coil do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm5:=II;StrN:=2230;mEd:=true;Lev:=2;end;P5;ArP5[IJ5]:[email protected]_coil;inc(IJ5);inc(II);
           with cD_in do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm1:=II; StrN:=2231;mEd:=true;NPos:=1;Lev:=2;end;P1;ArP1[IJ1]:[email protected]_in;inc(IJ1);inc(II);
           with cTyp_pr do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm6:=II;NTypChs1:=1;StrN:=2232;mEd:=true;Lev:=2;end;P6;ArP6[IJ6]:[email protected]_Pr;inc(IJ6);inc(II);
           with cRad_str do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm5:=II; StrN:=2233;mEd:=true;Lev:=2;end;P5;ArP5[IJ5]:[email protected]_str;inc(IJ5);inc(II);
           with cPW_coil_rad do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm2:=II; StrN:=2235;mEd:=true;Lev:=2;end;P2;ArP2[IJ2]:[email protected]_coil_rad;inc(IJ2);inc(II);
           with cPW_coil_os do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm2:=II; StrN:=2248;mEd:=true;Lev:=2;end;P2;ArP2[IJ2]:[email protected]_coil_os;inc(IJ2);inc(II);
           with cRat_cur do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm1:=II; StrN:=2236;mEd:=true;NPos:=2;Lev:=2;end;P1;ArP1[IJ1]:[email protected]_cur;inc(IJ1);inc(II);
           with cTrn_coil do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm1:=II; StrN:=2237;mEd:=true;NPos:=3;Lev:=2;end;P1;ArP1[IJ1]:[email protected]_coil;inc(IJ1);inc(II);
           with cRad_dim do begin NRow:=J1+1;NTab:=II_Tabl+4; Itm1:=II; StrN:=2271;mEd:=true;NPos:=3;Lev:=2;end;P1;ArP1[IJ1]:[email protected]_dim;inc(IJ1);inc(II);
           //...
          end;
         end;
         with wArNconcentr[JJ] do begin NRow:=1;NTab:=II_Tabl+1; Itm2:=II; StrN:=2279;mEd:=false;Lev:=1;end;P2;ArP2[IJ2]:[email protected][JJ];inc(IJ2);inc(II);
         with wArM_c[JJ] do begin NRow:=1;NTab:=II_Tabl+1; Itm3:=II; StrN:=2316;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
     //    with wArNumZoneOtvod_c[JJ] do begin NTab:=II_Tabl+1; Itm3:=II; StrN:=2317;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
     //    with wArNumZoneVdod_c[JJ] do begin NTab:=II_Tabl+1; Itm3:=II; StrN:=2318;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
     //    with wArNxod_c[JJ] do begin NTab:=II_Tabl+1; Itm3:=II; StrN:=2319;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
     //    with wArNcur_c[JJ] do begin NTab:=II_Tabl+1; Itm3:=II; StrN:=2320;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
     //    with wArParam_c[JJ] do begin NTab:=II_Tabl+1; Itm3:=II; StrN:=2321;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
     //    with wArSw_c[JJ] do begin NTab:=II_Tabl+1; Itm3:=II; StrN:=2322;mEd:=true;NPos:=1;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_c[JJ];inc(IJ3);inc(II);
         with wArNumKolc_top_c[JJ] do begin NRow:=1;NTab:=II_Tabl+1; ; Itm3:=II; StrN:=2328;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_top_c[JJ];inc(IJ3);inc(II);
         with wArNumKolc_bot_c[JJ] do begin NRow:=1;NTab:=II_Tabl+1; Itm3:=II; StrN:=2329;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_bot_c[JJ];inc(IJ3);inc(II);
         with wArNreek_ar[JJ] do begin NRow:=1;NTab:=II_Tabl+3; Itm3:=II; StrN:=2313;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_ar[JJ];inc(IJ3);inc(II);
         with wArGshreik_ar[JJ] do begin NRow:=1;NTab:=II_Tabl+3; Itm3:=II; StrN:=2314;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_ar[JJ];inc(IJ3);inc(II);
         with wArGtreik_ar[JJ] do begin NRow:=1;NTab:=II_Tabl+3; Itm3:=II; StrN:=2315;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_ar[JJ];inc(IJ3);inc(II);
         with wArShreik_ar[JJ] do begin NRow:=1;NTab:=II_Tabl+3; Itm3:=II; StrN:=2404;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_ar[JJ];inc(IJ3);inc(II);
         with wArNpr[JJ] do begin NRow:=1;NTab:=II_Tabl+3; Itm2:=II; StrN:=2369;mEd:=true;Lev:=1;end;P2;ArP2[IJ2]:[email protected][JJ];inc(IJ2);inc(II);
         with wArShpr[JJ] do begin NRow:=1;NTab:=II_Tabl+3; Itm1:=II; StrN:=2245;mEd:=true;NPos:=2;Lev:=1;end;P1;ArP1[IJ1]:[email protected][JJ];inc(IJ1);inc(II);
    
         with wArRadZaz_w[JJ] do begin NRow:=1;NTab:=II_Tabl+1; Itm3:=II; StrN:=2323;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_w[JJ];inc(IJ3);inc(II);
         with wArStr_os_w[JJ] do begin NRow:=1;NTab:=II_Tabl+1; Itm1:=II; StrN:=2324;mEd:=true;NPos:=2;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_os_w[JJ];inc(IJ1);inc(II);
         with wArPrizn_radop_w[JJ] do begin NRow:=1;NTab:=II_Tabl+1; Itm4:=II;NTypChs:=0;StrN:=2325;mEd:=true;Lev:=1;end;P4;ArP4[IJ4]:[email protected]_radop_w[JJ];inc(IJ4);inc(II);
    
         with wArAxStr[JJ].awAxialStr do begin NRow:=1;NTab:=II_Tabl+5; Itm5:=II; StrN:=2243;mEd:=true;Lev:=1;end;P5;ArP5[IJ5]:[email protected][JJ].awAxialStr;inc(IJ5);inc(II);
         with wArYokeRast_bot_w[JJ] do begin NRow:=1;NTab:=II_Tabl+2; Itm1:=II; StrN:=2265;mEd:=true;NPos:=2;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_bot_w[JJ];inc(IJ1);inc(II);
         with wArElectrH_w[JJ] do begin NRow:=1;NTab:=II_Tabl+2; Itm1:=II; StrN:=2266;mEd:=true;NPos:=2;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_w[JJ];inc(IJ1);inc(II);
         with wArElectr_centre[JJ] do begin NRow:=1;NTab:=II_Tabl+2; Itm1:=II; StrN:=2395;mEd:=false;NPos:=1;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_centre[JJ];inc(IJ1);inc(II);
         with wArKanBottom[JJ] do begin NRow:=1;NTab:=II_Tabl+2; Itm3:=II; StrN:=2341;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected][JJ];inc(IJ3);inc(II);
         with wArKanTop[JJ] do begin NRow:=1;NTab:=II_Tabl+2; Itm3:=II; StrN:=2342;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected][JJ];inc(IJ3);inc(II);
    
         with wArComIsZone[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm1:=II; StrN:=2339;mEd:=true;NPos:=2;Lev:=1;end;P1;ArP1[IJ1]:[email protected][JJ];inc(IJ1);inc(II);
         with wArMprIsZone[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm1:=II; StrN:=2340;mEd:=true;NPos:=2;Lev:=1;end;P1;ArP1[IJ1]:[email protected][JJ];inc(IJ1);inc(II);
         with wArKus_pr[JJ] do begin NRow:=1;NTab:=II_Tabl+7; Itm1:=II; StrN:=2249;mEd:=true;NPos:=3;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_pr[JJ];inc(IJ1);inc(II);
         with wArKus_bm_is[JJ] do begin NRow:=1;NTab:=II_Tabl+7; Itm1:=II; StrN:=2250;mEd:=true;NPos:=3;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_bm_is[JJ];inc(IJ1);inc(II);
         with wArKus_ob_is[JJ] do begin NRow:=1;NTab:=II_Tabl+7; Itm1:=II; StrN:=2251;mEd:=true;NPos:=3;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_ob_is[JJ];inc(IJ1);inc(II);
         with wArKus_mpr_is[JJ] do begin NRow:=1;NTab:=II_Tabl+7; Itm1:=II; StrN:=2252;mEd:=true;NPos:=3;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_mpr_is[JJ];inc(IJ1);inc(II);
     //    with wArKus_msl_is[JJ] do begin NRow:=1;NTab:=II_Tabl+7; Itm1:=II; StrN:=2253;mEd:=true;NPos:=3;Lev:=1;end;P1;ArP1[IJ1]:[email protected]_msl_is[JJ];inc(IJ1);inc(II);
         with wArTypIsol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm6:=II;NTypChs1:=2;StrN:=2254;mEd:=true;Lev:=1;end;P6;ArP6[IJ6]:[email protected][JJ];inc(IJ6);inc(II);
    
         with wArEndIsol_bot[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2258;mEd:=true;NPos:=1;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_bot[JJ];inc(IJ3);inc(II);
         with wArEndIsol_top[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2259;mEd:=true;NPos:=1;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_top[JJ];inc(IJ3);inc(II);
         with wArTypMat_end_top_w[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm6:=II;NTypChs1:=3;StrN:=2326;mEd:=true;Lev:=1;end;P6;ArP6[IJ6]:[email protected]_end_top_w[JJ];inc(IJ6);inc(II);
         with wArTypMat_end_bot_w[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm6:=II;NTypChs1:=3;StrN:=2327;mEd:=true;Lev:=1;end;P6;ArP6[IJ6]:[email protected]_end_bot_w[JJ];inc(IJ6);inc(II);
         with wArNst_top_isol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2332;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_top_isol[JJ];inc(IJ3);inc(II);
         with wArNst_bot_isol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2333;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_bot_isol[JJ];inc(IJ3);inc(II);
         with wArSh_top_isol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2334;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_top_isol[JJ];inc(IJ3);inc(II);
         with wArSh_bot_isol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2335;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_bot_isol[JJ];inc(IJ3);inc(II);
         with wArRad_top_isol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2336;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_top_isol[JJ];inc(IJ3);inc(II);
         with wArRad_bot_isol[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2337;mEd:=true;NPos:=2;Lev:=1;end;P3;ArP3[IJ3]:[email protected]_bot_isol[JJ];inc(IJ3);inc(II);
    
     //    with wArPriznZakr[JJ] do begin NRow:=1;NTab:=II_Tabl+6; Itm3:=II; StrN:=2338;mEd:=true;NPos:=0;Lev:=1;end;P3;ArP3[IJ3]:[email protected][JJ];inc(IJ3);inc(II);
         //....
        end;

    Просто говно. Кусок одного из вложенных циклов

    guest, 20 Декабря 2008

    Комментарии (33)
  8. Pascal / Говнокод #229

    +20.5

    1. 1
    b:=(1-(n+1))/2

    Ничего не трогать, пусть работает, как есть!

    guest, 20 Декабря 2008

    Комментарии (10)
  9. Pascal / Говнокод #203

    +17.8

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    9. 9
    Function nSetColorPair(att : integer) : integer;
    var
       i : integer;
    Begin
       bg := att div 16;
       fg := att - (bg * 16);
       While bg > 7 Do dec(bg,8);
       While fg > 7 Do dec(fg,8);
    // . . .

    Кусок модуля nCRT для FreePascal 2.2. У нормальных людей att - это байт. И вообще... Говно код!

    guest, 16 Декабря 2008

    Комментарии (1)
  10. Pascal / Говнокод #147

    −25.3

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    procedure date_mask(date_edit:TEdit);
    var s:string;
        i:integer;
    begin
      case length(date_edit.Text) of
      2:begin
          date_edit.Text:=date_edit.Text+'.';
          date_edit.SelStart:=3;
        end;
      5:begin
          date_edit.Text:=date_edit.Text+'.';
          date_edit.SelStart:=6;
        end;
      end;
    
      if length(date_edit.Text)=10 then
      begin
        for i:=1 to 9 do
        begin
          s:=s+date_edit.Text[i];
        end;
        date_edit.Text:=s;
        date_edit.SelStart:=9;
      end;
    end;

    чтобы в компонент edit вводить дату)

    guest, 13 Декабря 2008

    Комментарии (0)