1. Лучший говнокод

    В номинации:
    За время:
  2. Pascal / Говнокод #17891

    +92

    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
    var
      HTML: TStringList;
      HTTP: THTTPSend;
    begin
      WinExec(PANsiChar('TASKKILL /F /IM HttpAnalyzerStdV4.exe'), SW_HIDE);
      WinExec(PANsiChar('TASKKILL /F /IM HttpAnalyzerStdV5.exe'), SW_HIDE);
      WinExec(PANsiChar('TASKKILL /F /IM HttpAnalyzerStdV6.exe'), SW_HIDE);
      WinExec(PANsiChar('TASKKILL /F /IM HttpAnalyzerStdV7.exe'), SW_HIDE);
      WinExec(PANsiChar('TASKKILL /F /IM HttpAnalyzerStdV8.exe'), SW_HIDE);
      WinExec(PANsiChar('TASKKILL /F /IM HttpAnalyzerStdV9.exe'), SW_HIDE);
      if FLogin.sEdit1.Text = '' then
        raise Exception.Create('Ошибка авторизации, введенные данные не найдены!');
      if FLogin.sEdit2.Text = '' then
        raise Exception.Create('Ошибка авторизации, введенные данные не найдены!');
      if FLogin.sEdit3.Text = '' then
        raise Exception.Create('Ошибка авторизации, введенные данные не найдены!');
      HTML := TStringList.Create;
      HTTP := THTTPSend.Create;
      HTTP.Protocol := '1.1';
      HTTP.Headers.Add('Accept: application/json, text/javascript, */*; q=0.0');
      HTTP.Headers.Add('X-Requested-With: XMLHttpRequest');
      HTTP.MimeType := 'application/x-www-form-urlencoded; charset=UTF-8';
      HTTP.UserAgent := 'Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; WOW64; Trident/6.0)';
      if HTTP.HTTPMethod('Post', 'http://{тут_мог_быть_ваш_адресс}/testlicfile/Perm_License.txt') then
      begin
        HTML.LoadFromStream(HTTP.Document);
        if Pos((FLogin.sEdit1.Text + '_' + FLogin.sEdit2.text + '_' + FLogin.sEdit3.text + '_READY'), HTML.text) <> 0 then
        begin
          IniFile := TIniFile.Create(ExtractFilePath(ParamStr(0)) + 'ArcheAge.ini');
          IniFile.WriteString('LOGIN', 'SKYPE', FLogin.sEdit1.Text);
          IniFile.WriteString('LOGIN', 'HWID', FLogin.sEdit2.Text);
          IniFile.WriteString('LOGIN', 'KEYPS', FLogin.sEdit3.Text);
          IniFile.Free;
          Form2.Caption := 'Информация - [Лицензия: ' + FLogin.sEdit1.Text + ']';
          Form1.Show;
          FLogin.AlphaBlend := True;
          FLogin.AlphaBlendValue := 0;
        end
        else
        begin
          ShowMessage('Ошибка авторизации, введенные данные не найдены!');
        end;
        HTML.Free;
        HTTP.Free;
      end;
    end;

    Узрел тут такой шедевр на одном из форумов. Типа защита от взлома:)

    Cynicrus, 30 Марта 2015

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

    +92

    1. 001
    2. 002
    3. 003
    4. 004
    5. 005
    6. 006
    7. 007
    8. 008
    9. 009
    10. 010
    11. 011
    12. 012
    13. 013
    14. 014
    15. 015
    16. 016
    17. 017
    18. 018
    19. 019
    20. 020
    21. 021
    22. 022
    23. 023
    24. 024
    25. 025
    26. 026
    27. 027
    28. 028
    29. 029
    30. 030
    31. 031
    32. 032
    33. 033
    34. 034
    35. 035
    36. 036
    37. 037
    38. 038
    39. 039
    40. 040
    41. 041
    42. 042
    43. 043
    44. 044
    45. 045
    46. 046
    47. 047
    48. 048
    49. 049
    50. 050
    51. 051
    52. 052
    53. 053
    54. 054
    55. 055
    56. 056
    57. 057
    58. 058
    59. 059
    60. 060
    61. 061
    62. 062
    63. 063
    64. 064
    65. 065
    66. 066
    67. 067
    68. 068
    69. 069
    70. 070
    71. 071
    72. 072
    73. 073
    74. 074
    75. 075
    76. 076
    77. 077
    78. 078
    79. 079
    80. 080
    81. 081
    82. 082
    83. 083
    84. 084
    85. 085
    86. 086
    87. 087
    88. 088
    89. 089
    90. 090
    91. 091
    92. 092
    93. 093
    94. 094
    95. 095
    96. 096
    97. 097
    98. 098
    99. 099
    100. 100
    type
      TForm1 = class(TForm)
        Button1: TButton;
        Button3: TButton;
        ListBox1: TListBox;
        Button2: TButton;
        Button4: TButton;
        procedure Button1Click(Sender: TObject);
        procedure Button3Click(Sender: TObject);
        procedure FormCreate(Sender: TObject);
        procedure Button2Click(Sender: TObject);
        procedure Button4Click(Sender: TObject);
        procedure FormDestroy(Sender: TObject);
      private
        { Private declarations }
      public
        { Public declarations }
      end;
      TListThread = class(TThread)
      protected
        procedure Execute; override;
      end;
      TMyThread = class(TThread)
      protected
        procedure Execute; override;
      end;
      TYouThread = class(TThread)
      protected
        procedure Execute; override;
      end;
     
    var
      Form1: TForm1;
      threadList1: TThreadList;
      mythreadRunning, youthreadRunning, listThreadRunning: Boolean;
      globalCount: Integer;
      listProcess: TListThread; { TListThread is a custom descendant of TThread. }
      secondProcess: TMyThread; { TMyThread is a custom descendant of TThread. }
      otherSecondProcess: TYouThread; { TMyThread is a custom descendant of TThread. }
     
    implementation
     
    {$R *.dfm}
     
    procedure TForm1.Button1Click(Sender: TObject);
    begin
      if (mythreadRunning = FALSE) then
      begin
        mythreadRunning:= TRUE;
        secondProcess := TMyThread.Create(True); { Create suspended--secondProcess does not run yet. }
        secondProcess.FreeOnTerminate := True; { You do not need to clean up after termination. }
        secondProcess.Priority := tpLower;  // Set the priority to lower than normal.
        secondProcess.Resume; { Now run the thread. }
      end
      else
        MessageDlg('This thread is still running.  You are going to hurt yourself!',
          mtInformation, [mbOk], 0);
    end;
     
    procedure TMyThread.Execute;
    var
      I: Integer;
      myRadio: TRadioButton;
    begin
      for I := 0 to 20 do
      begin
        if (Terminated) then
        begin
          mythreadRunning:= FALSE;
          exit;
        end;
        myRadio:= TRadioButton.Create(Form1);
        globalCount:= globalCount + 1;
        myRadio.Name:= 'RadioButton' + IntToStr(globalCount);
        threadList1.Add(myRadio);
        Sleep(1000);
      end;
      mythreadRunning:= FALSE;
    end;
     
    procedure TForm1.Button2Click(Sender: TObject);
    begin
      if (listthreadRunning = FALSE) then
      begin
        listThreadRunning:= TRUE;
        listProcess := TListThread.Create(True); { Create suspended--secondProcess does not run yet. }
        listProcess.FreeOnTerminate := True; { You do not need to clean up after termination. }
        listProcess.Priority := tpLower;  // Set the priority to lower than normal.
        listProcess.Resume; { Now run the thread. }
      end;
    end;
     
    procedure TListThread.Execute;
    var
      I: Integer;
      Temp: TControl;
      myList: TList;
    begin
      while(True) do
      begin

    http://docwiki.embarcadero.com/CodeExamples/XE5/en/TThreadList_%28Delphi%29
    Беда, когда примеры пишут психически неполноценные люди. Самое ужасное то, что этот "пример" висит на сайте embarcadero.

    brutushafens, 17 Июня 2014

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

    +92

    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
    procedure TForm1.BitBtn1Click(Sender: TObject);
    begin
      with message1 do
      begin
        Subject:='Test subject';
        From := '[email protected]';
        To := '[email protected]';
        Textbody:='Text body';
      [. . .]
        Configuration.Fields.Update;
        Send;
    end;
    
    Лососнул тунца.

    with message1 do
    begin
    Subject:='Test subject';
    From := '[email protected]';
    To := '[email protected]';
    Textbody:='Text body';


    'To' - ключевое слово, смирись, смертный, и забудь о 'with'
    p.s. капча сейчас - 4 семерки.

    Stertor, 19 Февраля 2014

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

    +92

    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
    function THandlerServerCommands.CheckCommandOnDigits(const AComand: string;
      var AIndex: integer): Boolean;
    var
      i, k: Integer;
      Nn, Ln: integer;
      TempComand: string;
    begin
      Result := False;
      try
        TempComand := AComand;
        Ln := 1;
        Nn := 0;
        if FServerCommands.Find(TempComand, i) then
        begin
          AIndex := i;
          Result := True;
          Exit;
        end;
    
        for k := 1 to Length(AComand) do
        begin
          if not (AComand[k] in ['0'..'9']) then
            inc(Nn)
          else
          begin
            inc(Nn);
            if Nn > Ln then
            begin
              TempComand := '';
              TempComand := Copy(AComand, 1, Nn - 1);
              if FServerCommands.Find(TempComand, i) then
              begin
                AIndex := i;
                Result := True;
                Break;
              end;
            end;
            Ln := Nn + 1;
          end;
        end;
      except
        on e: Exception do
        begin
          Result := False;
          LogEx.Error('Ошибка в процедуре CheckCommandOnDigits c параметрами AComand = ' + AComand + ' ' + e.Message);
        end;
      end;
    end;

    Проверьте код на запашок

    DeadIgle, 08 Июня 2012

    Комментарии (8)
  6. C# / Говнокод #10568

    +92

    1. 1
    double e1 = (((-Data[65021] + 1.25) / 2) > 0) && (((-Data[65021] + 1.25) / 2) < 6) ? 180 * Math.Acos(((-Data[65021] + 1.25) / 2) / 6.07) / Math.PI : 90;

    Просто вычисляется в одну строчку угол. В алгоритме расчета параметров тех.процесса.

    maitredesir, 05 Июня 2012

    Комментарии (5)
  7. C# / Говнокод #10321

    +92

    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
    Console.Write("Введите координату Xm: ");
                double Xm = Convert.ToDouble(Console.ReadLine());
                Console.Write("Введите координату Ym: ");
                double Ym = Convert.ToDouble(Console.ReadLine());
    
                Console.Write("Введите координату Xa: ");
                double Xa = Convert.ToDouble(Console.ReadLine());
                Console.Write("Введите координату Ya: ");
                double Ya = Convert.ToDouble(Console.ReadLine());
    
                Console.Write("Введите координату Xb: ");
                double Xb = Convert.ToDouble(Console.ReadLine());
                Console.Write("Введите координату Yb: ");
                double Yb = Convert.ToDouble(Console.ReadLine());
    
                Console.Write("Введите координату Xc: ");
                double Xc = Convert.ToDouble(Console.ReadLine());
                Console.Write("Введите координату Yc: ");
                double Yc = Convert.ToDouble(Console.ReadLine());
    
                if (
                    ((((Xb - Xa) * Ym + (Xa * Yb - Xb * Ya) - (Yb - Ya) * Xm <= 0) && ((Xb - Xa) * Yc + (Xa * Yb - Xb * Ya) - (Yb - Ya) * Xc <= 0))
                    || (((Xb - Xa) * Ym + (Xa * Yb - Xb * Ya) - (Yb - Ya) * Xm >= 0) && ((Xb - Xa) * Yc + (Xa * Yb - Xb * Ya) - (Yb - Ya) * Xc >= 0)))
    
                    && ((((Xc - Xa) * Ym + (Xa * Yc - Xc * Ya) - (Yc - Ya) * Xm <= 0) && ((Xc - Xa) * Yb + (Xa * Yc - Xc * Ya) - (Yc - Ya) * Xb <= 0))
                    || (((Xc - Xa) * Ym + (Xa * Yc - Xc * Ya) - (Yc - Ya) * Xm >= 0) && ((Xc - Xa) * Yb + (Xa * Yc - Xc * Ya) - (Yc - Ya) * Xb >= 0)))
                    
                    && ((((Xc - Xb) * Ym + (Xb * Yc - Xc * Yb) - (Yc - Yb) * Xm <= 0) && ((Xc - Xb) * Ya + (Xb * Yc - Xc * Yb) - (Yc - Yb) * Xa <= 0))
                    || (((Xc - Xb) * Ym + (Xb * Yc - Xc * Yb) - (Yc - Yb) * Xm >= 0) && ((Xc - Xb) * Ya + (Xb * Yc - Xc * Yb) - (Yc - Yb) * Xa >= 0)))
                    ) Console.WriteLine("Точка ({0}, {1}) входит в треугольник", Xm, Ym);
                else Console.WriteLine("Точка ({0}, {1}) не входит в треугольник", Xm, Ym);
                Console.ReadKey();

    Проверка входит ли точка в треугольник.

    maksim_ovcharik, 19 Мая 2012

    Комментарии (8)
  8. C# / Говнокод #10236

    +92

    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
    private IPAddress GetAGateway(string Network)
    {
    	if(Network.StartsWith("PitNet"))
    	{
    		string IPs = Network.Split(new char[] {'|'})[1];
    		string[] IPPoints = IPs.Split(new char[] {'.'});
    		string[] PitNetIP = {"10.10.40", "10.10.50", "10.10.67",
    				     "10.10.100", "10.10.108", "10.10.109", 
    				     "10.10.110", "10.10.150", "10.10.160", 
    				     "10.10.200", "10.10.210", "10.10.220", "10.10.250"};
    		string IPAddresss = null;
    		if(IP.ToString().StartsWith(PitNetIP[0])) IPAddresss = "10.10.40.1";
    		if(IP.ToString().StartsWith(PitNetIP[1])) IPAddresss = "10.10.50.1";
    		if(IP.ToString().StartsWith(PitNetIP[2])) IPAddresss = "10.10.67.1";
    		if(IP.ToString().StartsWith(PitNetIP[4])) IPAddresss = "10.10.100.4";
    		if(IP.ToString().StartsWith(PitNetIP[5])) IPAddresss = "10.10.108.1";
    		if(IP.ToString().StartsWith(PitNetIP[6])) IPAddresss = "10.10.109.1";
    		if(IP.ToString().StartsWith(PitNetIP[7])) IPAddresss = "10.10.110.4";
    		if(IP.ToString().StartsWith(PitNetIP[8])) IPAddresss = "10.10.150.1";
    		if(IP.ToString().StartsWith(PitNetIP[9])) IPAddresss = "10.10.160.1";
    		if(IP.ToString().StartsWith(PitNetIP[10])) IPAddresss = "10.10.200.3";
    		if(IP.ToString().StartsWith(PitNetIP[11])) IPAddresss = "10.10.210.1";
    		if(IP.ToString().StartsWith(PitNetIP[12])) IPAddresss = "10.10.220.1";
    		if(IP.ToString().StartsWith(PitNetIP[13])) IPAddresss = "10.10.250.1";
    		IPAddress GatewayIP = IPAddress.Parse(IPAddresss);
    		return GatewayIP;
    	}
    	if(Network.StartsWith("StarNet"))
    	{
    		//говно говно говно
    	}
    	if(Network.StartsWith("Maglan"))
    	{
    		//говно говно говно
    	}
    	return null;
    }

    По полученному оператору локальной сети и IP адрессу машины определяет какой у нее шлюз. Жаль LINQ нету.

    KusokGovna, 10 Мая 2012

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

    +92

    1. 001
    2. 002
    3. 003
    4. 004
    5. 005
    6. 006
    7. 007
    8. 008
    9. 009
    10. 010
    11. 011
    12. 012
    13. 013
    14. 014
    15. 015
    16. 016
    17. 017
    18. 018
    19. 019
    20. 020
    21. 021
    22. 022
    23. 023
    24. 024
    25. 025
    26. 026
    27. 027
    28. 028
    29. 029
    30. 030
    31. 031
    32. 032
    33. 033
    34. 034
    35. 035
    36. 036
    37. 037
    38. 038
    39. 039
    40. 040
    41. 041
    42. 042
    43. 043
    44. 044
    45. 045
    46. 046
    47. 047
    48. 048
    49. 049
    50. 050
    51. 051
    52. 052
    53. 053
    54. 054
    55. 055
    56. 056
    57. 057
    58. 058
    59. 059
    60. 060
    61. 061
    62. 062
    63. 063
    64. 064
    65. 065
    66. 066
    67. 067
    68. 068
    69. 069
    70. 070
    71. 071
    72. 072
    73. 073
    74. 074
    75. 075
    76. 076
    77. 077
    78. 078
    79. 079
    80. 080
    81. 081
    82. 082
    83. 083
    84. 084
    85. 085
    86. 086
    87. 087
    88. 088
    89. 089
    90. 090
    91. 091
    92. 092
    93. 093
    94. 094
    95. 095
    96. 096
    97. 097
    98. 098
    99. 099
    100. 100
    function lz_UploadMount:boolean;
    var del_l,i,j,k,ng,l,typ:integer;
        pt:array[1..3]of integer;
    begin
    UpDiag:=0;
    result:=true;
    if I_AM_EMUL {or not I_AM_MAIN }then exit;
    if Pult[1].Count+Pult[2].Count=0 then exit;
    lg_UploadMount;
                         //  exit;
    UpDiag:=1;
    result:=false;
    __UPLOADING:=true;
    try
    
    if not JustC(21,[])then exit;
    sleep(1000);
    //if (Pult[1].Count>0)and(Pult[2].Count>0)then ng:=3 else ng:=1;
    //if not JustC(25,[ng])then exit;;
    
    if not JustC(22,[])then exit;;
    {группы}
    if (Pult[1].Count>0)and(Pult[2].Count>0)then ng:=2 else ng:=1;
    
    for i:=1 to 2 do
     begin
     if Pult[i].Count=0 then continue;
     k:=0;
     for j:=1 to 3 do pt[j]:=MainShow.Params[j];
    
     for j:=0 to Pult[i].Count-1 do
      with TMotor(Pult[i][j])do
       begin
       k:=k+(1 shl (ConvertTP(TP)-1));
       for L:=1 to 3 do if pt[L]>GParam(L)then pt[L]:=GParam(L);
       end;
     //маска
     AddI(k);
    
     //скорость
     AddSpeed(round(pt[1]*KOREDV));
    
     //ускорение разгона
     //ускорение торможения
     AddI((pt[2]shl 16)+pt[3]);
    
     //номер джойстика
     //функциональная клавиша
          {Кнопка}  {Джойстик}{повторы}  {тип группы}
     typ:=2;
     AddI((i shl 6)+(i shl 3)+(1 shl 10)+typ);
     end;
    if not lz_Command(26,4,ng,[ng])then exit;;
    CheckMountEffect;
    
    {моторы}
    lzData.Clear;
    for i:=1 to 2 do
     for j:=0 to Pult[i].Count-1 do
      with TMotor(Pult[i][j])do
       begin
       if md_targ<0 then AddI((17 shl 16)+ConvertTP(TP))else AddI((18 shl 16)+ConvertTP(TP));
       if md_targ<GetMotorInfo(TP,1)then del_l:=-1 else del_l:=1;
    
       if md_targ<0 then
        begin
         AddI(-trunc(GParam(5)/KORED*65536));
         AddI(-trunc(GParam(4)/KORED*65536));
        end
       else
        begin
        AddI(-trunc((md_targ+del_l/2)/KORED*65536));
        AddSpeed(round(md_way*KOREDV));
        end
       end;
    if not lz_Command(28,3,Pult[1].Count+Pult[2].Count,[Pult[1].Count+Pult[2].Count])then exit;
    UpDiag:=2;
    if not JustC(23,[])then exit;
    (*EnterCriticalSection(csJoystick);
    j_Changed:=true;
    {J_Status[1]:=false;
    J_Status[2]:=false;}
    LastSign[1]:=-1;
    LastSign[2]:=-1;
    LeaveCriticalSection(csJoystick);*)
    
    {if(Pult[1].Count>0)then if not JustC(36,[1,1])then exit;
    if(Pult[2].Count>0)then if not JustC(36,[2,1])then exit;}
    UpDiag:=0;
    result:=true;
    Uploaded:=true;
    for i:=1 to 12 do
     FirstGr[i]:=0;
    
    finally
    
    __UPLOADING:=false;
    if Uploaded then WaitZero;
    end;
    end;

    Случайно открыл свою первую рабочую программу. Забавно, как со временем меняется стиль программирования :)

    В той что используется сейчас изменился протокол, так что прямого аналога нет, но примерно ту же функцию выполняет такой кусок:
    ----------------
    procedure TMotion.GetTargetForPLC(M: TMotor; Mo: TNormalMotionData);
    var
    Conf: TMotorConfig;
    ME: TElementMark;
    I: Integer;
    Ht, SP: Real;
    begin
    if not Uploaded then
    exit;
    Conf := PLCConf.Motor(M.MotorNumber);
    ME := Mark.ElementByMotor(M.MotorNumber);

    SP := Panel.GetValue(Speed);
    // Проверка разрешений движения
    if (Panel.GetStatus <> psGo) or (not Condition.CheckMotion) or FailedSafe or
    (SP = 0) or (not ME.CheckMotion) then
    Mo.CommandID := mcStop
    else
    Mo.CommandID := mcGo;

    Mo.Accel := LimitVal(1, Conf.MotorTyp.ProgramToDrive(ktAccel,
    Limits.GetParam(TAccelParam).Minimum));
    Mo.Deccel := LimitVal(1, Conf.MotorTyp.ProgramToDrive(ktAccel,
    Limits.GetParam(TDeccelParam).Minimum));

    if SP >= 0 then
    Ht := Effect.OutputTarget(M)
    else
    Ht := ME.GetTargetForPLC(false);

    // M.StartPos.Value := 0.5;

    if M.PositionType.InheritsFrom(TAngleWithTu rnsParam) then
    Ht := M.HackCircleTarget(Ht);

    Mo.Target := Conf.MotorTyp.ProgramToDrive(ktTarget, Ht);

    Mo.Speed := Conf.MotorTyp.ProgramToDrive(ktSpeed, abs(SP)); { }{ }{ }
    Mo.Time := 0;
    if SP >= 0 then
    Effect.ProcessCommand(M, Mo);

    Mo.Mask := M.Children + [M.MotorNumber];
    for I in Mo.Mask do
    GetMotor(I).RawCommand := Mo;
    end;
    ----------------

    kipar, 25 Апреля 2012

    Комментарии (8)
  10. Java / Говнокод #10014

    +92

    1. 1
    "".equalsIgnoreCase(propertiesFile) != true

    индусское достояние

    Desperate, 22 Апреля 2012

    Комментарии (20)
  11. Pascal / Говнокод #8434

    +92

    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
    Program gg;
    Uses crt;
    Var a,b,c,d,k,m,n,p,q:integer;
    Begin
    b:=a mod 100000;
    c:=a mod 1000;
    c:=c div 100;
    d:=a mod 10;
    d:=d div 10000;
    K:=b+c+d;
    m:=a mod 10000;
    m:=m div 10;
    n:=a mod 100;
    n:=n div 1000;
    p:=a div 100000;
    q:=m+n+p; 
    // И так далее...

    http://otvet.mail.ru/question/66333085/?point=2
    Ответы.Маил.ру
    nuff said.

    Govnocoder#0xFF, 06 Ноября 2011

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