import java.io.*; import java.net.*; import java.awt.*; import java.util.*; public class Server{ public static void main(String argumendid[]) throws IOException{ ServerSocket ss=new ServerSocket(3001); Vector uhendused=new Vector(); while(true){ Socket sc=ss.accept(); new Serverloim(sc, uhendused); } } } class Serverloim extends Thread{ Vector v; Socket sc; public Serverloim(Socket uus_sc, Vector uus_v){ v=uus_v; sc=uus_sc; v.add(sc); start(); } public void run(){ try{ PrintWriter valja=new PrintWriter(sc.getOutputStream(), true); BufferedReader sisse=new BufferedReader( new InputStreamReader(sc.getInputStream()) ); BufferedReader sisse3=new BufferedReader( new FileReader("konnad.txt") ); BufferedReader sisse2=new BufferedReader( new FileReader("konnad.txt") ); String rida=""; int x=0; while (rida!=null){ rida=sisse2.readLine(); x=x+1; } int y=0; rida=""; if (v.size()x){ int n=0; x=x-1; n=v.size()-x; while (n>x ){ n=n-x; } if (n==x){ y=0; while (y