import java.io.*; import java.net.*; import java.util.Vector; public class server{ public static void main(String argumendid[]) throws IOException{ ServerSocket ss=new ServerSocket(4021); Vector uhendused=new Vector(); while(true){ Socket sc=ss.accept(); uhendused.add(sc); new JututoaLoim(sc, uhendused); } } } class JututoaLoim extends Thread{ Vector v; Socket sc; public JututoaLoim(Socket uus_sc, Vector uus_v){ v=uus_v; sc=uus_sc; start(); } public void run(){ try{ BufferedReader sisse=new BufferedReader( new InputStreamReader(sc.getInputStream()) ); boolean veel=true; while(veel){ try{ String rida=sisse.readLine(); System.out.println(rida); if(rida.startsWith(".ots"))veel=false; for(int i=0; i