public
Created

Pythonic Java

  • Download Gist
gistfile1.java
Java
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
import java.net.* ;
import java.io.* ;
import java.util.* ;
public class Server {
public static void main( String[] args) {
try {
ServerSocket sock = new ServerSocket(4712,100) ;
while(true) new Handler(sock.accept()).start() ;}
catch(IOException e) {
System.err.println(e) ;};}}
 
class Handler extends Thread {
public void run() {
Random random=new Random() ;
try {
//yada yada yada
catch(Exception e) {
System.err.println(e) ;};}}

Thanks to http://stackoverflow.com/questions/237719/what-is-the-most-frustrating-programming-style-youve-encountered

(I didn't want to attribute in a comment, as that would ruin the Python with Java Comments)

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.