Voting

Category

real language

Bookmarking

Del.icio.us Digg Diigo DZone Earthlink Google Kick.ie
Windows Live LookLater Ma.gnolia Reddit Rojo StumbleUpon Technorati

Language Java

(bytecode-version with loader)

Date:05/23/06
Author:Tilo Dickopp
URL:http://www.tiloswelt.de/
Comments:10
Info:n/a
Score: (3.07 in 479 votes)
public class BeerSongLoader extends ClassLoader {
  private static final String BEER_SONG =
	  
    " #$%MBVC?*9@QW68Q986@9                                                                   " +
    " @6######%##%@#9####9                                                                 " +
    "   #C##@#9#   ##$##9#?#                                                                 " +
    "   #Q#?##W    #?##6#9#                                                                 " +
    "   #8##$##9    ###$##$#         ?##$$#?##           $%#?##$M#?         ##$B#?#  #$V#?#  " +
    "   #$C#?##$?    #9###$##       $*#C##$9#9##$@       ##$Q#9##$W##$6   #C##$8#### V%QV*V6V " +
    "   *CM%6####%$?$*BV##       ##MM%V8   VMVB##   ##?CMV8B  %CMC$V*  V6VC###M$?$*MQV9V " +
    "   CVV$8VQVV6VC$8B%CMC$    V*V6VC%    @#Q##B  ##V###    CV9VC   VV$8VQVV6VC$8B%C " +
    "   MC$V*V6VCM$CBV*VQVMVBC$  ###%WC@%#$QV%V?V8V* V%VB$Q%#$%V6V8$#VWV   8C$VB$#V$  V8CMCM  " +
    "   VQVBC%CQ%     $%%$#V$V 8CMCMVQVBCQ%%QC@%#  CW$#V$V8CMCMVQVBC%C   W$#V8VV$#          " +
    "   V$VBVBC$#     ###V6## ##M6#C##            %##Q##%              ##%$#Q##           " +
    "   %%##%M##     ##6$#V8V6$  #CMV?VB$#           CCVVQVQ$             Q$#####$          " +
    "  $6#9###$WC   @%#$QV%V?V    8V*V%VB$Q%#$%MCV8   $#CMV8$#CMV?VB$#C%   CMV8C$VB$          " +
    "  #VV6VM$#V$CBC*$#C%V8VWV      B$#VWV8C$VB###$    VCQ%#%QBMVV@VB$  #V8V6VB$#VMV8C      " +
    " CV6$#VV6VM$#C#VC%C%$#          V*CM$#VC$V         8CBV6VMCW$Q$    #####$C@%###      " +
    "                                                                                          " +
    " ##$C@%####8$#V8V6$#C                                                                   " +
    " MV?VB$#CCVVQVQ$6#9#9#Q#                                                                 " +
    "   #?##*#   ###V9VCV                                                                 " +
    "   V$8VQVV    6VC$8M8V$                                                                 " +
    "   V9VBV%CM#    C##%B#Q##         %V##%C#C#           #%?#Q##%*#         #%9###  #?M$VB  " +
    "   VBC$B%V8V    6VC###       #V9VCVV$8VQV       V6VC$8B%CMC$V   *V6VC####C C$VBC#VQ " +
    "   VV%VB###MM$?MQV9V       CVV$8V   QVV6VC   $8M%V?V  C$B%VBC  CBVBV6V%VB%@MQV9VC " +
    "   VV$8VQVV6VC$8M%V?VC    $B%VBC    CBVBV6V  %VB%@$*M    QV9VCV   V$8VQVV6VC$8B%CM " +
    "   C$V*V6VC%@####VVC#C#V  BV6VM###$W$?MQV9VC VV$8VQVV6VC$8B%CM   C$V*V6VC%  @$*MQV  " +
    "   9VCVV$8     VQVV6VC$8 B%CMC$V*V6VCM$CBV*V  QVMVBC$%@###V9V   CVV$8VQV          " +
    "   V6VC$8M*     V6CMVBVCVB C$####CC            VVVQCBV              BM8VV##           " +
    "   #V$?M*$*     MQV9VCVV  $8VQVV6V           C$8M*V6CM             VBVCVBC$%          " +
    "  @###CV9V   CVV$8CMVB    C?CM$8MWVBC%C%VV   CVBMVV8C$VWVCM##   ##VVVV8C$          " +
    "  VWVCM###%*$?MQV9VCVV      $8VQVV6VC$8B%CM    C$V*V6VC%@B@MQV9  VCVV$8VQVV6      " +
    " VC$8M8V$V9VBV%CM%@$*MQV          9VCVV$8VQ         VV6VC$8B%CM    C$V*V6VC%@##$      " +
    "                                                                                          " +
    " ##M#############$##                                                                   " +
    " ###B##V#####C######                                                                 " +
    "   ######   #######B$                                                                 " +
    "   9@C###@    #########                                                                 " +
    "   ####?##    *#####         C######?V           ###C###M##         ####C9@  @###$B  " +
    "   *@C###%MQ    #V%%WQ       *@##V*$#MM6$@       @@###$B*@C###%   $W$#B$#V@ V###C@V# " +
    "   ##?$#*@V###?$W@V###       ?$#9@V   ###?$#   @@V###?  $#Q@V##  #?$W$#W$#6@V###C@V " +
    "   ###?$#8@V###?@V####B    @W##B    *#%Q@?  ##$B%B*    #MQ#V   %V##VMC#@?##$B%@ " +
    "   ?##%@V###?BC?M#$889C88  **$@@V###@######### ####C$*MQCC@@#V*?   M%V*Q9?C%  BQ%CM  " +
    "   @C9V@Q8C$     *@6#M9B%6 %@Q*B6#C?CQ?*9WQ%9  9QVC#89B#*6CQ%#*B   V?9$9QMV          " +
    "   M@Q@V6V88     8V9@W96M$ ??V8M@C%            %**MQ@*              $VC%$@*           " +
    "   C8?M98QC     #M$9W%$6B9  VV$$WCMQ           $%#W8#QB             ?W8C?$W9@          " +
    "  96C9@V?%$*6   89BVWV@W8@    VM$M#CC8V$@M$6M*%   V#$MC6W#%%%*8#CM@   M*B@%9$W?          " +
    "  $9$99M$?*8B$VM8CCCW6W@*      %W%CC?@#?B8@W%9    ?*%$9B%8Q*BQ$Q9  6@V9#?V98C$M$M      " +
    " M@%??C88M$86M$QVWC?B?V          Q%B8#%?MQ         B6BM?B9@#$%    WQMW?BBBB?#6      ";

  @Override public Class<?> loadClass(String name) throws ClassNotFoundException {
    String alphabet = "";
    byte[] code = new byte[946];
    int i = 0, j = 0;
    boolean firstNibble = false;
    while (i < 946) {
      while (BEER_SONG.charAt(j) == ' ') j++;
      if (alphabet.length() < 16)
        alphabet += BEER_SONG.charAt(j++);
      else if (firstNibble = !firstNibble)
        code[i] = (byte)(alphabet.indexOf(BEER_SONG.charAt(j++)) * 16);
      else
        code[i++] += alphabet.indexOf(BEER_SONG.charAt(j++));
    }
    return name.equals("BeerSong") ? defineClass(name, code, 0, 946) 
                                   : findSystemClass(name);
  }

  public static void main(String[] args) throws Throwable {
    Class<?> beerSong = new BeerSongLoader().loadClass("BeerSong");
    System.out.println(beerSong.newInstance());
  }
}

Download Source | Write Comment

Alternative Versions

VersionAuthorDateCommentsRate
object-oriented versionAnonymous04/20/0533
exception orientedJarek Ratajski09/08/055
standard versionSean Russell04/20/0512
Java 5.0 object-oriented versionKvols11/19/053
Singing with Java Speech APIKevin Seifert05/04/062

Comments

>>  SM said on 06/07/06 21:54:10

SM Much cooler than these cheapy eyedrop-perl thing. I like it!

>>  nameless said on 08/31/06 09:22:27

nameless Sorry for my stupidity, but how to run it?

>>  Luis Carlos F. Dias said on 10/26/06 23:27:35

Luis Carlos F. Dias to nameless:

Save the source in a file named BeerSongLoader.java and run:

javac BeerSongLoader.java

java BeerSongLoader

>>  ssilagi said on 05/09/07 12:51:21

ssilagi Very cool!!! nice job...

>>  skywriter14 said on 06/19/07 04:15:23

skywriter14 @SM:
Keep hating. Someday there will be one programming language in this world. Only for guys like you. We shall all die to make you happy.

>>  Alex Mirchev said on 07/12/07 18:32:38

Alex Mirchev That language is definatly java.. btw, why is your code so weird... it doesnt look like a correct syntax...

>>  Robstown Holanda said on 10/04/07 21:56:26

Robstown Holanda very good, congratulations

>>  Homer said on 12/09/07 17:36:41

Homer Fantastic!!!

You're the greatest freak ever seen ;-)

>>  Eduardo Costa said on 09/16/09 13:44:33

Eduardo Costa Good Lord! This is awesome! Mix ASCII art and bytecode programming... Wow...

>>  jean123 said on 06/07/10 18:32:54

jean123 seller cheap off


1 US CVV = 5$
1 UK CVV = 10$
1 EU CVV = 15$
FULL CC with mmn,ssn,dob,pin = pm me for price


US Dumps:
US Mix (20Gold/20Plats/20Biz&Corp/40MCstandard&Classic)
bin of my choice = 20$
US Classic = 40$
US Debit Classic 40$
US MC Standard = 50$
US Gold = 70$
US Platinum = 120$
US Business/Corporate = 120$
US Purchasing/Signature = 150$
US MC World = 120$

Canada Dumps:
Canada Classic = 50$
Canada MC Standard = 60$
Canada Gold = 120$
Canada Platinum = 150$
Canada MC World = 120$

Europe Dumps:
EU Classic = 50$
EU MC Standard = 60$
EU Gold = 120$
EU Platinum = 150$
EU Business/Corporate = 150$
EU Infinite = 200$


Asia Classic = 50$
Asia MC Standard = 60$
Asia Gold = 120$
Asia Platinum/Business/Corporate = 150$

Atm Skimmer Wincor Nixdorf = 3000$
Atm Skimmer Wincor = 3000$
Atm Skimmer Slimm = 3000$
Atm Skimmer Slim = 3000$
Atm Skimmer NCR = 3000$
Atm Skimmer Diebold Opteva = 2500$
Atm Skimmer Diebold = 2000$
Atm Skimmer Universal = 4000$
Atm Skimmer Small = 2500$
MRS...................... 1200$
MSR-206-3HL

MSR 250

Uniform MSR 206

LCM Portable PROMAG
contact me

america_skimmer@yahoo.fr

Download Source | Write Comment

Add Comment

Please provide a value for the fields Name, Comment and Security Code.
This is a gravatar-friendly website.
E-mail addresses will never be shown.
Enter your e-mail address to use your gravatar.

Please don't post large portions of code here! Use the form to submit new examples or updates instead!

Name:

eMail:

URL:

Security Code:
  
Comment: