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

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

    +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
    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
    90. 90
    function country_code_to_country( $code ){
        $country = '';
        if( $code == 'AF' ) $country = 'Afghanistan';
        if( $code == 'AX' ) $country = 'Aland Islands';
        if( $code == 'AL' ) $country = 'Albania';
        if( $code == 'DZ' ) $country = 'Algeria';
        if( $code == 'AS' ) $country = 'American Samoa';
        if( $code == 'AD' ) $country = 'Andorra';
        if( $code == 'AO' ) $country = 'Angola';
        if( $code == 'AI' ) $country = 'Anguilla';
        if( $code == 'AQ' ) $country = 'Antarctica';
        if( $code == 'AG' ) $country = 'Antigua and Barbuda';
        if( $code == 'AR' ) $country = 'Argentina';
        if( $code == 'AM' ) $country = 'Armenia';
        if( $code == 'AW' ) $country = 'Aruba';
        if( $code == 'AU' ) $country = 'Australia';
        if( $code == 'AT' ) $country = 'Austria';
        if( $code == 'AZ' ) $country = 'Azerbaijan';
        if( $code == 'BS' ) $country = 'Bahamas the';
        if( $code == 'BH' ) $country = 'Bahrain';
        if( $code == 'BD' ) $country = 'Bangladesh';
        if( $code == 'BB' ) $country = 'Barbados';
        if( $code == 'BY' ) $country = 'Belarus';
        if( $code == 'BE' ) $country = 'Belgium';
        if( $code == 'BZ' ) $country = 'Belize';
        if( $code == 'BJ' ) $country = 'Benin';
        if( $code == 'BM' ) $country = 'Bermuda';
        if( $code == 'BT' ) $country = 'Bhutan';
        if( $code == 'BO' ) $country = 'Bolivia';
        if( $code == 'BA' ) $country = 'Bosnia and Herzegovina';
        if( $code == 'BW' ) $country = 'Botswana';
        if( $code == 'BV' ) $country = 'Bouvet Island (Bouvetoya)';
        if( $code == 'BR' ) $country = 'Brazil';
        if( $code == 'IO' ) $country = 'British Indian Ocean Territory (Chagos Archipelago)';
        if( $code == 'VG' ) $country = 'British Virgin Islands';
        if( $code == 'BN' ) $country = 'Brunei Darussalam';
        if( $code == 'BG' ) $country = 'Bulgaria';
        if( $code == 'BF' ) $country = 'Burkina Faso';
        if( $code == 'BI' ) $country = 'Burundi';
        if( $code == 'KH' ) $country = 'Cambodia';
        if( $code == 'CM' ) $country = 'Cameroon';
        if( $code == 'CA' ) $country = 'Canada';
        if( $code == 'CV' ) $country = 'Cape Verde';
        if( $code == 'KY' ) $country = 'Cayman Islands';
        if( $code == 'CF' ) $country = 'Central African Republic';
        if( $code == 'TD' ) $country = 'Chad';
        if( $code == 'CL' ) $country = 'Chile';
        if( $code == 'CN' ) $country = 'China';
        if( $code == 'CX' ) $country = 'Christmas Island';
        if( $code == 'CC' ) $country = 'Cocos (Keeling) Islands';
        if( $code == 'CO' ) $country = 'Colombia';
        if( $code == 'KM' ) $country = 'Comoros the';
        if( $code == 'CD' ) $country = 'Congo';
        if( $code == 'CG' ) $country = 'Congo the';
        if( $code == 'CK' ) $country = 'Cook Islands';
        if( $code == 'CR' ) $country = 'Costa Rica';
        if( $code == 'CI' ) $country = 'Cote d\'Ivoire';
        if( $code == 'HR' ) $country = 'Croatia';
        if( $code == 'CU' ) $country = 'Cuba';
        if( $code == 'CY' ) $country = 'Cyprus';
        if( $code == 'CZ' ) $country = 'Czech Republic';
        if( $code == 'DK' ) $country = 'Denmark';
        if( $code == 'DJ' ) $country = 'Djibouti';
        if( $code == 'DM' ) $country = 'Dominica';
        if( $code == 'DO' ) $country = 'Dominican Republic';
        if( $code == 'EC' ) $country = 'Ecuador';
        if( $code == 'EG' ) $country = 'Egypt';
        if( $code == 'SV' ) $country = 'El Salvador';
        if( $code == 'GQ' ) $country = 'Equatorial Guinea';
        if( $code == 'ER' ) $country = 'Eritrea';
        if( $code == 'EE' ) $country = 'Estonia';
        if( $code == 'ET' ) $country = 'Ethiopia';
        if( $code == 'FO' ) $country = 'Faroe Islands';
        if( $code == 'FK' ) $country = 'Falkland Islands (Malvinas)';
        if( $code == 'FJ' ) $country = 'Fiji the Fiji Islands';
        if( $code == 'FI' ) $country = 'Finland';
        if( $code == 'FR' ) $country = 'France, French Republic';
        if( $code == 'GF' ) $country = 'French Guiana';
        if( $code == 'PF' ) $country = 'French Polynesia';
        ----------------------------------------------------------------
        if( $code == 'VE' ) $country = 'Venezuela';
        if( $code == 'VN' ) $country = 'Vietnam';
        if( $code == 'WF' ) $country = 'Wallis and Futuna';
        if( $code == 'EH' ) $country = 'Western Sahara';
        if( $code == 'YE' ) $country = 'Yemen';
        if( $code == 'ZM' ) $country = 'Zambia';
        if( $code == 'ZW' ) $country = 'Zimbabwe';
        if( $country == '') $country = $code;
        return $country;
    }

    Кто-то очень много старался

    win32, 08 Октября 2014

    Комментарии (3)
  3. Java / Говнокод #16824

    +83

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    TextView v = (TextView)
                            ((RelativeLayout)
                                ((AbsoluteLayout)
                                    ((LinearLayout)
                                        ((RelativeLayout)(
                                            (LinearLayout)activty.findViewById(R.id.container)).getChildAt(1))
                                        .getChildAt(0))
                                    .getChildAt(element))
                                .getChildAt(0))
                            .getChildAt(0);

    (Android)

    когда нет idшников...

    danpetruk, 08 Октября 2014

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

    +134

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    SDL_Rect sr = {
    		e->outputRect.x,
    		e->outputRect.y+e->lineHeight*line,
    		e->outputRect.w,
    		sr.y + e->lineHeight };

    laMer007, 06 Октября 2014

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

    +120

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    /* Writing: cosine = (double (*)(double)) dlsym(handle, "cos");
           would seem more natural, but the C99 standard leaves
           casting from "void *" to a function pointer undefined.
           The assignment used below is the POSIX.1-2003 (Technical
           Corrigendum 1) workaround; see the Rationale for the
           POSIX specification of dlsym(). */
    
    *(void **) (&cosine) = dlsym(handle, "cos");

    Сишкопроблемы.

    http://linux.die.net/man/3/dlsym

    someone, 28 Сентября 2014

    Комментарии (3)
  6. SQL / Говнокод #16761

    −119

    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
    select *
      from (  select ... ,
                     case
                        when     txn_minute >= date '2014-08-01'
                             and txn_minute < date '2014-08-02'
                        then
                           '1 августа'
                        when     txn_minute >= date '2014-08-02'
                             and txn_minute < date '2014-08-03'
                        then
                           '2 августа'
                        when     txn_minute >= date '2014-08-03'
                             and txn_minute < date '2014-08-04'
                        then
                           '3 августа'
                        when     txn_minute >= date '2014-08-04'
                             and txn_minute < date '2014-08-05'
                        then
                           '4 августа'
                        when     txn_minute >= date '2014-08-05'
                             and txn_minute < date '2014-08-06'
                        then
                           '5 августа'
                       ..... 
                        when     txn_minute >= date '2014-08-31'
                             and txn_minute < date '2014-09-01'
                        then
                           '31 августа'
                     end
                        "Дата"
                from txn
               where     txn_minute >= date '2014-08-01'
                     and txn_minute < date '2014-09-01'
            group by ..... 
                    ..... 
                     end) pivot (sum (am)
                          for "Дата"
                          in  ('1 августа',
                    .....
                              '29 августа',
                              '30 августа',
                              '31 августа'))

    Кто-то подсказал правильное решение :-)

    Djayn, 24 Сентября 2014

    Комментарии (3)
  7. PHP / Говнокод #16729

    +159

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    if (!empty($params['manager_select'])) {
                $rings = $phone_manager->getManagerRings($manager_id, $dateBegin, $dateEnd, $params['is_incoming_select'], $is_marked, $select_all_rings, $params, $managers_groups_arr, $only_not_effected, $order_params, $find_phone_number);
            } else {
                $rings = $phone_manager->getManagerRings($manager_id, $dateBegin, $dateEnd, $params['is_incoming_select'], $is_marked, $select_all_rings, NULL, $managers_groups_arr, $only_not_effected, $order_params, $find_phone_number);
            }

    Шик! Убил бы за такое

    howard, 19 Сентября 2014

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

    +53

    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
    // quick render params menu actions
        if(pe->buttons()&Qt::LeftButton || pe->buttons()&Qt::RightButton){
            //
            if(cRenderMenuOpended){//
                if((p.x()+p.y())<18){//   - -
                    cRenderMenuOpended=!cRenderMenuOpended;
                    repaint();
                    return;
                }
                else if(p.x()>5 && p.y()>5 && p.x()<145 && p.y()<cRenderMenuHeight){// actions rectangle
                    //
                    //sliceModifyMode=true; // show slice plane and can be modified
                    //useSlicePlane=true;   // build geometry with slice plane
                    if(cViewType==0){// 2D
                        if(p.x()>10 && p.y()>22 && p.x()<140 && p.y()<38){
                            // reset zoom
                            if(c2DZoom1To1){
                                cPanFor2DX1to1=0;
                                cPanFor2D=0;
                                cPanFor2DX=0;
                                cZoomFor2D=1;
    
                                if(cViewType==0 && c2DZoom1To1 && renderLimits){
                                    auto testSizeX=cVieportXSize;
                                    auto testSizeY=cVieportYSize;
    
                                    BoundaryConditionsOfComposite *cond=NULL;
                                    cond=AbstractContainer::getInstance()->getBoundaryCondition(0);
                                    if(cond->isHeatFlux_multiple()){
                                        cPanFor2D+=15;
                                        testSizeY-=20;
                                    }
                                    if(cond->isHeatFlux_multiple() || cond->isHeatFlux() || cond->isHeatPower() || cond->isConvection() || cond->isInsulated() || cond->isTemperature()){
                                        cPanFor2D+=20;
                                        testSizeY-=25;
                                    }
    
                                    cond=AbstractContainer::getInstance()->getBoundaryCondition(3);
                                    if(cond->isHeatFlux() || cond->isHeatPower() || cond->isConvection() || cond->isInsulated() || cond->isTemperature()){
                                        testSizeX-=35;
                                        cPanFor2DX1to1+=30;
                                    }
                                    cond=AbstractContainer::getInstance()->getBoundaryCondition(1);
                                    if(cond->isHeatFlux() || cond->isHeatPower() || cond->isConvection() || cond->isInsulated() || cond->isTemperature()){
                                        testSizeX-=35;
                                    }
    
                                    if(cWidth>cThikness){
                                        cZoomFor2D=(double(testSizeX)-50.0)/(zoomed2DX(width_sub_start)-zoomed2DX(width_sub_end));
                                    }
                                    else{
                                        cZoomFor2D=(double(testSizeY)-50.0)/(zoomed2DY(thickness_sub_start)-zoomed2DY(thickness_sub_end));
                                    }
                                }
                            }
                            else{
                                cZoomFor2D=1;
                                cPanFor2D=0;
                                cPanFor2DX=0;
                            }
    
                            repaint();
                            return;
                        }
                        else if(p.x()>10 && p.y()>42 && p.x()<140 && p.y()<58){
                            cForbidRenderResultsOverLayers=!cForbidRenderResultsOverLayers;
                            repaint();
                            return;
                        }
                        else if(p.x()>10 && p.y()>62 && p.x()<140 && p.y()<78){
                            renderLimits++;
                            if(renderLimits>1){
                                renderLimits=0;
                            }
                            repaint();
                            return;
                        }
                        else if(p.x()>10 && p.y()>82 && p.x()<140 && p.y()<98){
                            SLOT_swap2DMode11AndScaled();
                            return;
                        }
                        else if(p.x()>106 && p.y()>92 && p.x()<122 && p.y()<118){
                            cResTransparency-=0.1;
                            if(cResTransparency<0){cResTransparency=0;}
                            repaint();
                            return;
                        }
                        else if(p.x()>124 && p.y()>92 && p.x()<140 && p.y()<118){
                            cResTransparency+=0.1;
                            if(cResTransparency>1){cResTransparency=1;}
                            repaint();
                            return;
                        }
                    }
                    else{//3D
                        if(p.x()>10 && p.y()>22 && p.x()<140 && p.y()<38){
                            slot_swapCoordiantes();
                            return;
                        }
                        else if(p.x()>10 && p.y()>42 && p.x()<140 && p.y()<58){

    Магия чисел в построении GUI

    Abbath, 17 Сентября 2014

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

    +136

    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
    if(GUI.Button(Rect(100,50,50,50),NewTexture[0])) 
    { Change = true; Clicks += 1; GridNumber = 0;   }
    if(GUI.Button(Rect(150,50,50,50),NewTexture[1])) 
    { Change = true; Clicks += 1; GridNumber = 1;   }
    if(GUI.Button(Rect(200,50,50,50),NewTexture[2])) 
    { Change = true; Clicks += 1; GridNumber = 2;   }
    if(GUI.Button(Rect(250,50,50,50),NewTexture[3])) 
    { Change = true; Clicks += 1; GridNumber = 3;   }
    if(GUI.Button(Rect(300,50,50,50),NewTexture[4])) 
    { Change = true; Clicks += 1; GridNumber = 4;   }
    if(GUI.Button(Rect(350,50,50,50),NewTexture[5])) 
    { Change = true; Clicks += 1; GridNumber = 5;   }
    if(GUI.Button(Rect(400,50,50,50),NewTexture[6])) 
    { Change = true; Clicks += 1; GridNumber = 6;   }
    if(GUI.Button(Rect(100,100,50,50),NewTexture[7])) 
    { Change = true; Clicks += 1; GridNumber = 7;   }
    if(GUI.Button(Rect(150,100,50,50),NewTexture[8])) 
    { Change = true; Clicks += 1; GridNumber = 8;   }
    if(GUI.Button(Rect(200,100,50,50),NewTexture[9])) 
    { Change = true; Clicks += 1; GridNumber = 9;   }
    if(GUI.Button(Rect(250,100,50,50),NewTexture[10])) 
    { Change = true; Clicks += 1; GridNumber = 10;  }
    if(GUI.Button(Rect(300,100,50,50),NewTexture[11])) 
    { Change = true; Clicks += 1; GridNumber = 11;  }
    if(GUI.Button(Rect(350,100,50,50),NewTexture[12])) 
    { Change = true; Clicks += 1; GridNumber = 12;  }
    if(GUI.Button(Rect(400,100,50,50),NewTexture[13])) 
    { Change = true; Clicks += 1; GridNumber = 13;  }
    if(GUI.Button(Rect(100,150,50,50),NewTexture[14])) 
    { Change = true; Clicks += 1; GridNumber = 14;  }
    if(GUI.Button(Rect(150,150,50,50),NewTexture[15])) 
    { Change = true; Clicks += 1; GridNumber = 15;  }
    if(GUI.Button(Rect(200,150,50,50),NewTexture[16])) 
    { Change = true; Clicks += 1; GridNumber = 16;  }
    if(GUI.Button(Rect(250,150,50,50),NewTexture[17])) 
    { Change = true; Clicks += 1; GridNumber = 17;  }
    if(GUI.Button(Rect(300,150,50,50),NewTexture[18])) 
    { Change = true; Clicks += 1; GridNumber = 18;  }
    if(GUI.Button(Rect(350,150,50,50),NewTexture[19])) 
    { Change = true; Clicks += 1; GridNumber = 19;  }
    if(GUI.Button(Rect(400,150,50,50),NewTexture[20])) 
    { Change = true; Clicks += 1; GridNumber = 20;  }
    if(GUI.Button(Rect(100,200,50,50),NewTexture[21])) 
    { Change = true; Clicks += 1; GridNumber = 21;  }
    if(GUI.Button(Rect(150,200,50,50),NewTexture[22])) 
    { Change = true; Clicks += 1; GridNumber = 22;  }
    if(GUI.Button(Rect(200,200,50,50),NewTexture[23])) 
    { Change = true; Clicks += 1; GridNumber = 23;  }
    if(GUI.Button(Rect(250,200,50,50),NewTexture[24])) 
    { Change = true; Clicks += 1; GridNumber = 24;  }
    if(GUI.Button(Rect(300,200,50,50),NewTexture[25])) 
    { Change = true; Clicks += 1; GridNumber = 25;  }
    if(GUI.Button(Rect(350,200,50,50),NewTexture[26])) 
    { Change = true; Clicks += 1; GridNumber = 26;  }
    if(GUI.Button(Rect(400,200,50,50),NewTexture[27])) 
    { Change = true; Clicks += 1; GridNumber = 27;  }
    if(GUI.Button(Rect(100,250,50,50),NewTexture[28])) 
    { Change = true; Clicks += 1; GridNumber = 28;  }
    if(GUI.Button(Rect(150,250,50,50),NewTexture[29])) 
    { Change = true; Clicks += 1; GridNumber = 29;  }
    if(GUI.Button(Rect(200,250,50,50),NewTexture[30])) 
    { Change = true; Clicks += 1; GridNumber = 30;  }
    if(GUI.Button(Rect(250,250,50,50),NewTexture[31])) 
    { Change = true; Clicks += 1; GridNumber = 31;  }
    if(GUI.Button(Rect(300,250,50,50),NewTexture[32])) 
    { Change = true; Clicks += 1; GridNumber = 32;  }
    if(GUI.Button(Rect(350,250,50,50),NewTexture[33])) 
    { Change = true; Clicks += 1; GridNumber = 33;  }
    if(GUI.Button(Rect(400,250,50,50),NewTexture[34])) 
    { Change = true; Clicks += 1; GridNumber = 34;  }
    if(GUI.Button(Rect(400,350,50,50),NewTexture[40])) 
    { Change = true; Clicks += 1; GridNumber = 40;  }
    if(GUI.Button(Rect(450,350,50,50),NewTexture[41])) 
    { Change = true; Clicks += 1; GridNumber = 41;  }
    if(GUI.Button(Rect(500,350,50,50),NewTexture[42])) 
    { Change = true; Clicks += 1; GridNumber = 42;  }
    ...
    if(GUI.Button(Rect(100,550,65,65),NewTexture[35])) 
    { Change = true; Clicks += 1; GridNumber = 35; }
    if(GUI.Button(Rect(165,550,65,65),NewTexture[36])) 
    { Change = true; Clicks += 1; GridNumber = 36; }
    if(GUI.Button(Rect(230,550,65,65),NewTexture[37])) 
    { Change = true; Clicks += 1; GridNumber = 37; }
    if(GUI.Button(Rect(295,550,65,65),NewTexture[38])) 
    { Change = true; Clicks += 1; GridNumber = 38; }
    if(GUI.Button(Rect(360,550,65,65),NewTexture[39])) 
    { Change = true; Clicks += 1; GridNumber = 39; }

    http://answers.unity3d.com/questions/691870/gui-button-not-showing-up.html

    dzzpchelka, 12 Сентября 2014

    Комментарии (3)
  10. Objective C / Говнокод #16673

    −402

    1. 1
    2. 2
    3. 3
    4. 4
    UIDevice* thisDevice = [UIDevice currentDevice];
        char cfunktion[] = {'u', 'n', 'i', 'q', 'u', 'e', 'I', 'd', 'e', 'n', 't', 'i', 'f', 'i', 'e', 'r',0};
        SEL udid = NSSelectorFromString([NSString stringWithUTF8String:cfunktion]);
        id identifier =[thisDevice performSelector:udid];

    Безпалевно вызываем скрытые апи.

    Psionic, 09 Сентября 2014

    Комментарии (3)
  11. Java / Говнокод #16646

    +73

    1. 1
    Class <? extends Object> currentClass = Class.forName( clazz )

    Продолжаем разговор...

    sakkath, 05 Сентября 2014

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