1. C++ / Говнокод #7742

    +164

    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
    ULONG LCard791::SetChn(int _gain,int _channel)
    {
    		ULONG ret;
    		if(isDiff)
    				ret=_channel&15;
    		else
    		{
    				ret=_channel&31;
    				ret|=1<<5;
    		}
    		int gain;
    		switch(_gain)
    		{
    		case 1:
    				gain=0;
    				break;
    		case 2:
    				gain=1;
    				break;
    		case 4:
    				gain=2;
    				break;
    		case 8:
    				gain=3;
    				break;
    		case 16:
    				gain=4;
    				break;
    		case 32:
    				gain=5;
    				break;
    		case 64:
    				gain=6;
    				break;
    		case 128:
    				gain=7;
    				break;
    		default:
    				gain=0;
    		}
    		ret|=gain<<6;
    		return(ret);
    }

    Есть у нас один мужик, которые такие шедевры творит. Хакер сновидений, РАГ - мы с тобой!

    phys-tech, 02 Сентября 2011

    Комментарии (55)
  2. Python / Говнокод #7741

    −181

    1. 1
    d = dialog.Dialog(dialog = "dialog")

    Ехал Грека через реку

    _test, 02 Сентября 2011

    Комментарии (21)
  3. ActionScript / Говнокод #7740

    −119

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    private function onEnterFrame(e:Event):void { 
       if (success)
        {
        }
       else
       {
        }
    }

    24 раза в секунду: "У вас всё хорошо? Вот и славно. Всё плохо? Да и чёрт с ним."

    robin, 02 Сентября 2011

    Комментарии (6)
  4. JavaScript / Говнокод #7739

    +158

    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
    $(document).ready(function(){
    	i=1;
    	$("#go_pr").click(function () {
    		i=i-1;
    		if (i==0) {i=4;}
    		$('.diva').hide('fade');
    		$('#s'+i).show('fade');
    		$('.go').removeClass('acti');
    		$('#go'+i).addClass('acti');
    		return false;
    	});
    	$("#go_nx").click(function () {
    		i=i+1;
    		if (i==5) {i=1;}
    		$('.diva').hide('fade');
    		$('#s'+i).show('fade');
    		$('.go').removeClass('acti');
    		$('#go'+i).addClass('acti');
    		return false;
    	});
    	$("#go1").click(function () {
    		i=1;
    		$('.diva').hide('fade');
    		$('#s1').show('fade');
    		$('.go').removeClass('acti');
    		$(this).addClass('acti');
    	});
    	$("#go2").click(function () {
    		i=2;
    		$('.diva').hide('fade');
    		$('#s2').show('fade');
    		$('.go').removeClass('acti');
    		$(this).addClass('acti');
    	});
    	$("#go3").click(function () {
    		i=3;
    		$('.diva').hide('fade');
    		$('#s3').show('fade');
    		$('.go').removeClass('acti');
    		$(this).addClass('acti');
    	});
    	$("#go4").click(function () {
    		i=4;
    		$('.diva').hide('fade');
    		$('#s4').show('fade');
    		$('.go').removeClass('acti');
    		$(this).addClass('acti');
    	});
    });

    andrew_crunchdeal, 02 Сентября 2011

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

    +147

    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
    template<typename _Tp>
        pair<_Tp*, ptrdiff_t>
        get_temporary_buffer(ptrdiff_t __len)
        {
          const ptrdiff_t __max =
      __gnu_cxx::__numeric_traits<ptrdiff_t>::__max / sizeof(_Tp);
          if (__len > __max)
      __len = __max;
          
          while (__len > 0) 
      {
        _Tp* __tmp = static_cast<_Tp*>(::operator new(__len * sizeof(_Tp), 
                  std::nothrow));
        if (__tmp != 0)
          return std::pair<_Tp*, ptrdiff_t>(__tmp, __len);
        __len /= 2;                                    // !?!?!?!?!?!?!?!?
      }
          return std::pair<_Tp*, ptrdiff_t>(static_cast<_Tp*>(0), 0);
        }
    
      template<typename _Tp>
        inline void
        return_temporary_buffer(_Tp* __p)
        { ::operator delete(__p, std::nothrow); }

    CPPGovno, 02 Сентября 2011

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

    +153

    1. 1
    2. 2
    3. 3
    bool (A::*F[2])(int);
    //...
    return (this->*F[n])(i);

    CPPGovno, 02 Сентября 2011

    Комментарии (2)
  7. Куча / Говнокод #7736

    +144

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    Говнокод за последние 2 года превратился в унылое говно и с этим ничего не поделаешь.
    Постится одна хуйня, толпа бешеных долбоёбов минусует всё подряд, половина из выложенного - откровенный троллинг.
    Все поливают друг друга говном и меряются письками как в детском саду.
    Это что по-вашему govnocomment.ru?
    Сосните хуйцов, уроды.

    Fai, 02 Сентября 2011

    Комментарии (37)
  8. Куча / Говнокод #7735

    +138

    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
    error LNK2001: unresolved external symbol "private: static class std::map<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class 
    std::map<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class
     std::map<__int64,class k3bufferblock,struct std::less<__int64>,class std::allocator<struct 
    std::pair<__int64 const ,class k3bufferblock> > >,struct std::less<class std::basic_string<char,struct 
    std::char_traits<char>,class std::allocator<char> > >,class std::allocator<struct std::pair<class 
    std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const ,class 
    std::map<__int64,class k3bufferblock,struct std::less<__int64>,class std::allocator<struct 
    std::pair<__int64 const ,class k3bufferblock> > > > > >,struct std::less<class 
    std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > >,class 
    std::allocator<struct std::pair<class std::basic_string<char,struct std::char_traits<char>,class 
    std::allocator<char> > const ,class std::map<class std::basic_string<char,struct 
    std::char_traits<char>,class std::allocator<char> >,class std::map<__int64,class k3bufferblock,struct 
    std::less<__int64>,class std::allocator<struct std::pair<__int64 const ,class k3bufferblock> > >,struct 
    std::less<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > 
    >,class std::allocator<struct std::pair<class std::basic_string<char,struct std::char_traits<char>,class 
    std::allocator<char> > const ,class std::map<__int64,class k3bufferblock,struct 
    std::less<__int64>,class std::allocator<struct std::pair<__int64 const ,class k3bufferblock> > > > > > 
    > > > k3entity_cache::buffercache" (?buffercache@k3entity_cache@@0V?$map@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V?$map@V?$basic_string@DU?
    $char_traits@D@std@@V?$allocator@D@2@@std@@V?$map@_JVk3bufferblock@@U?$less@_J@std@@V?$allocator@U?$pair@$$CB_JVk3bufferblock@@@std@@@3@@2@U?$less@V?
    $basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@2@V?$allocator@U?$pair@$$CBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V?
    $map@_JVk3bufferblock@@U?$less@_J@std@@V?$allocator@U?$pair@$$CB_JVk3bufferblock@@@std@@@3@@2@@std@@@2@@2@U?$less@V?$basic_string@DU?
    $char_traits@D@std@@V?$allocator@D@2@@std@@@2@V?$allocator@U?$pair@$$CBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V?$map@V?$basic_string@DU?
    $char_traits@D@std@@V?$allocator@D@2@@std@@V?$map@_JVk3bufferblock@@U?$less@_J@std@@V?$allocator@U?$pair@$$CB_JVk3bufferblock@@@std@@@3@@2@U?$less@V?
    $basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@2@V?$allocator@U?$pair@$$CBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V?
    $map@_JVk3bufferblock@@U?$less@_J@std@@V?$allocator@U?$pair@$$CB_JVk3bufferblock@@@std@@@3@@2@@std@@@2@@2@@std@@@2@@std@@A)

    CPPGovno, 02 Сентября 2011

    Комментарии (3)
  9. C++ / Говнокод #7734

    +147

    1. 1
    int (*arr)[3];

    CPPGovno, 02 Сентября 2011

    Комментарии (0)
  10. C++ / Говнокод #7733

    +147

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    struct VS_INPUT_STRUCT //вхідні дані
    {
        float4 position: POSITION;
        float3 normal:   NORMAL;
    };
    
    struct VS_OUTPUT_STRUCT //вихідні дані
    {
         float4 position: POSITION;
         float3 light:    TEXCOORD0;
         float3 normal:   TEXCOORD1;
    };

    CPPGovno, 01 Сентября 2011

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