What's wrong with this code
import java.io.IOException; import java.net.ServerSocket; import java.net.Socket; /** * * @author Master */ public class Server { try { ServerSocket S = new ServerSocket(3333); Socket So = S.accept(); } catch(IOException e) { System.out.println("IOError"); } } Firstly I wrote the code without try catch and I got an unreported exception java.io.IOException; must be caught or declared to be thrown Error but Netbeans didn't suggest that I add a try-catch block . Now I added the try-catch block manually but It still shows an error and suggests that I must add another try-catch block !
