Shop OBEX P1 Docs P2 Docs Learn Events
Shortest self-printing java program... — Parallax Forums

Shortest self-printing java program...

Ryan ClarkeRyan Clarke Posts: 738
edited 2005-10-06 15:49 in General Discussion
Just thought this was interesting. The GNU guys have a listing of the smallest 'self-printing' java code they could find:

class _{static{new _(){{System.out.print((_+=(char)34)+_+';'+'}');}};System.exit(0);}String _="class _{static{new _(){{System.out.print((_+=(char)34)+_+';'+'}');}};System.exit(0);}String _=";}


[noparse];)[/noparse]

Ryan

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Ryan Clarke
Parallax Tech Support

RClarke@Parallax.com
Sign In or Register to comment.