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

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

    +147

    1. 1
    {"width":910,"element":null,"appto":null,"random_seed":874464,"html":"<div style='width:910' class='animated_pic_group' id='re874464'><a href='\/\/' class='animated_image'> \n<table class='kartinko_s_tenju'>\n    <tr>\n        <td><div class='tl'><\/div><\/td>\n        <td><div class='top'><\/div><\/td>\n        <td><div class='tr'><\/div><\/td>\n    <\/tr>\n    <tr>\n        <td height='100%' class='left'><\/td>\n        <td><div class='image'><img src='\/images\/up\/image1.jpg' width='150px'><\/div><\/td>\n        <td class='right'><\/td>\n    <\/tr>\n    <tr>\n        <td><div class='bl'><\/div><\/td>\n        <td><div class='bottom'><\/div><\/td>\n        <td><div class='br'><\/div><\/td>\n    <\/tr>\n<\/table>\n        \n        <\/a><a href='\/\/' class='animated_image'> \n<table class='kartinko_s_tenju'>\n    <tr>\n        <td><div class='tl'><\/div><\/td>\n        <td><div class='top'><\/div><\/td>\n        <td><div class='tr'><\/div><\/td>\n    <\/tr>\n    <tr>\n        <td height='100%' class='left'><\/td>\n        <td><div class='image'><img src='\/images\/up\/image2.jpg' width='150px'><\/div><\/td>\n        <td class='right'><\/td>\n    <\/tr>\n    <tr>\n        <td><div class='bl'><\/div><\/td>\n        <td><div class='bottom'><\/div><\/td>\n        <td><div class='br'><\/div><\/td>\n    <\/tr>\n<\/table>\n        \n        <\/a><a href='\/\/' class='animated_image'> \n<table class='kartinko_s_tenju'>\n    <tr>\n        <td><div class='tl'><\/div><\/td>\n        <td><div class='top'><\/div><\/td>\n        <td><div class='tr'><\/div><\/td>\n    <\/tr>\n    <tr>\n        <td height='100%' class='left'><\/td>\n        <td><div class='image'><img src='\/images\/up\/image3.jpg' width='150px'><\/div><\/td>\n        <td class='right'><\/td>\n    <\/tr>\n    <tr>\n        <td><div class='bl'><\/div><\/td>\n        <td><div class='bottom'><\/div><\/td>\n        <td><div class='br'><\/div><\/td>\n    <\/tr>\n<\/table>\n        \n        <\/a><a href='\/\/' class='animated_image'> \n<table class='kartinko_s_tenju'>\n    <tr>\n        <td><div class='tl'><\/div><\/td>\n        <td><div class='top'><\/div><\/td>\n        <td><div class='tr'><\/div><\/td>\n    <\/tr>\n    <tr>\n        <td height='100%' class='left'><\/td>\n        <td><div class='image'><img src='\/images\/up\/image4.jpg' width='150px'><\/div><\/td>\n        <td class='right'><\/td>\n    <\/tr>\n    <tr>\n        <td><div class='bl'><\/div><\/td>\n        <td><div class='bottom'><\/div><\/td>\n        <td><div class='br'><\/div><\/td>\n    <\/tr>\n<\/table>\n        \n        <\/a><a href='\/\/' class='animated_image'> \n<table class='kartinko_s_tenju'>\n    <tr>\n        <td><div class='tl'><\/div><\/td>\n        <td><div class='top'><\/div><\/td>\n        <td><div class='tr'><\/div><\/td>\n    <\/tr>\n    <tr>\n        <td height='100%' class='left'><\/td>\n        <td><div class='image'><img src='\/images\/up\/image5.jpg' width='150px'><\/div><\/td>\n        <td class='right'><\/td>\n    <\/tr>\n    <tr>\n        <td><div class='bl'><\/div><\/td>\n        <td><div class='bottom'><\/div><\/td>\n        <td><div class='br'><\/div><\/td>\n    <\/tr>\n<\/table>\n        \n        <\/a><\/div> "}

    вот такой вот json

    guest, 06 Июля 2009

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

    +163

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    $to = date("m.d.Y");
    $to=explode('.',$to);
    $k = $to[0];
    $to[0]=$to[1];
    $to[1]=$k;
    $to = array_reverse($to);
    $to = implode('-', $to);

    делаем дату в формате sql

    guest, 30 Июня 2009

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

    −104

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    9. 9
    bash-3.2# pacman -Rsn mysql
    проверка зависимостей...
    ошибка: не удалось продолжить операцию (не удается удовлетворить зависимости)
    :: akonadi: требует mysql
    bash-3.2# pacman -Rsn akonadi
    проверка зависимостей...
    ошибка: не удалось продолжить операцию (не удается удовлетворить зависимости)
    :: kdemod-kdepimlibs: требует akonadi>=1.1.1
    bash-3.2#

    guest, 16 Июня 2009

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

    +226.4

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    ....
    	bic.w	#C,SR
    	rrc.w	R6
    	rra.w	R6
    	rra.w	R6
    	rra.w	R6
    	rra.w	R6
    ....

    Когда проц не делит аппартно....

    guest, 13 Июня 2009

    Комментарии (6)
  6. Perl / Говнокод #1175

    −207.6

    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
    #sub load_midi_positions_random {
    ##
    ## Вот понапишут такого кода, а потом системные администраторы виноваты что сервер тормозит ;-) ....
    ## У Вас есть  враги ? Подарите им этот уникальный код !
    ##.
    #
    #    my $dbh = get_pg_connect();
    #    my $sql = "SELECT count(id) FROM midi_data where name<>'Unsorted'";
    #    my $sth = $dbh->prepare($sql) or die $DBI::errstr;
    #    $sth->execute or die $DBI::errstr;
    #    my $i=$sth->fetchrow();
    #    $sth->finish or die $DBI::errstr;
    #....
    #my    $PIC_COUNT=$i;
    #my    $pic1 = int (rand($i));
    #my    $pic2 = int (rand($i));
    #my $count=0;
    #    while ($pic1 == $pic2 && $count < 20){
    #        $pic2 = int (rand($PIC_COUNT));
    #        $count++;
    #    }
    #    my $pic3 = int (rand($PIC_COUNT));
    #    $count = 0;
    #    while (($pic1 == $pic3 || $pic2 == $pic3 || $pic2 == $pic1) && $count < 20){
    #        $pic3 = int (rand($PIC_COUNT));
    #        $count++;
    #    }
    #    my $pic4 = int (rand($PIC_COUNT));
    #    $count = 0;
    #    while (($pic1 == $pic2 || $pic1 == $pic3 || $pic1 == $pic4  || $pic2 == $pic3 || $pic2 == $pic4  || $pic3 == $pic4) && $count < 20){
    #        $pic4 = int (rand($PIC_COUNT));
    #        $count++;
    #    }
    #    my $pic5 = int (rand($PIC_COUNT));
    #    $count = 0;
    #    while (($pic1 == $pic2 || $pic1 == $pic3 || $pic1 == $pic4  || $pic2 == $pic3 || $pic2 == $pic4  || $pic3 == $pic4 || $pic1 == $pic5 || $pic2 == $pic5
    #    || $pic3 == $pic5 || $pic4 == $pic5) && $count < 20){
    #        $pic5 = int (rand($PIC_COUNT));
    #        $count++;
    #    }
    #    my $pic6 = int (rand($PIC_COUNT));
    #    $count = 0;
    #    while (($pic1 == $pic2 || $pic1 == $pic3 || $pic1 == $pic4  || $pic2 == $pic3 || $pic2 == $pic4  || $pic3 == $pic4 || $pic1 == $pic5 || $pic2 == $pic5
    #    || $pic3 == $pic5 || $pic4 == $pic5
    #    || $pic1 == $pic6 || $pic2 == $pic6 || $pic3 == $pic6 || $pic4 == $pic6 || $pic5 == $pic6  ) && $count < 20){
    #        $pic6 = int (rand($PIC_COUNT));
    #        $count++;
    #    }
    #    my $pic7 = int (rand($PIC_COUNT));
    #    $count = 0;
    #    while (($pic1 == $pic2 || $pic1 == $pic3 || $pic1 == $pic4  || $pic2 == $pic3 || $pic2 == $pic4  || $pic3 == $pic4 || $pic1 == $pic5 || $pic2 == $pic5
    #    || $pic3 == $pic5 || $pic4 == $pic5
    #    || $pic1 == $pic6 || $pic2 == $pic6 || $pic3 == $pic6 || $pic4 == $pic6 || $pic5 == $pic6..
    #    || $pic1 == $pic7 || $pic2 == $pic7 || $pic3 == $pic7 || $pic4 == $pic7 || $pic5 == $pic7  || $pic6 == $pic7) && $count < 20
    #
    #    ){
    #        $pic6 = int (rand($PIC_COUNT));
    #        $count++;
    #    }
    #
    #    $sql = "SELECT * FROM midi_data where name<>'Unsorted' order by id";
    #    $sth = $dbh->prepare($sql) or die $DBI::errstr;
    #    $sth->execute or die $DBI::errstr;
    #    my @result;
    #    while(my @row = $sth->fetchrow){
    #        my $tmp = split_midi_position(@row);
    #    	$tmp->{POSITION_NAME}=~ s/(\d{4})//;
    #	$tmp->{POSITION_YEAR}=$1;
    #        push @result, $tmp;....
    #    }
    #my @new=();
    #$new[0]=$result[$pic1];
    #$new[1]=$result[$pic2];
    #$new[2]=$result[$pic3];
    #$new[3]=$result[$pic4];
    #$new[4]=$result[$pic5];
    #$new[5]=$result[$pic6];
    #$new[6]=$result[$pic7];
    #$sth->finish or die $DBI::errstr;
    #    return @new;
    #}
    ###

    Таблица midi_data > 15000 записей.
    Этот код вызывался несколько раз в секунду...

    guest, 10 Июня 2009

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

    +142.7

    1. 1
    <p><img src="./?<?php echo name()?>=<?php echo id()?>"></p>

    guest, 05 Июня 2009

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

    −98

    1. 1
    if (!EventManager.getInstance().hasEventListener("START_NEW_LEVEL")) EventManager.getInstance().addEventListener("START_NEW_LEVEL", preCreateLevel);

    guest, 04 Июня 2009

    Комментарии (6)
  9. PHP / Говнокод #1118

    +62.5

    1. 1
    2. 2
    3. 3
    4. 4
    5. 5
    6. 6
    7. 7
    8. 8
    9. 9
    require_once ("lib/bsyscall.inc");
    require_once ("lib/page.inc");
    
    	push		( "hello" );
    	push		( new Page() );
    	pop		( $r );
    	pop		($t);
    	page_init	($r, $t);
    	push		( $r );

    Не говнокод, но поржать можно.
    Запускал. Реально создает страницу:)

    guest, 01 Июня 2009

    Комментарии (6)
  10. PHP / Говнокод #1102

    +153

    1. 1
    2. 2
    3. 3
    4. 4
    class RequiredLibraryClassNotFoundInALibraryDirectoryException extends Exception
    {
    //...
    }

    Ну и имя у класса:)

    guest, 28 Мая 2009

    Комментарии (6)
  11. Assembler / Говнокод #1088

    +236

    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
    evalLOG:
    	JB kod.7, log8
    	JB kod.6, log7
    	JB kod.5, log6
    	JB kod.4, log5
    	JB kod.3, log4
    	JB kod.2, log3
    	JB kod.1, log2
    	JB kod.0, log1
    		Mov log, #0
    		JMP exiteval
    log8:
    	Mov log, #8
    	JMP exiteval
    log7:
    	Mov log, #7
    	JMP exiteval
    log6:
    	Mov log, #6
    	JMP exiteval
    log5:
    	Mov log, #5
    	JMP exiteval
    log4:
    	Mov log, #4
    	JMP exiteval
    log3:
    	Mov log, #3
    	JMP exiteval
    log2:
    	Mov log, #2
    	JMP exiteval
    log1:
    	Mov log, #1
    exiteval:
    	Ret

    Нахождение логарифма восьмибитного числа с точностью до целых на ассемблере x51.

    guest, 25 Мая 2009

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