Comment on Tutorial - Simple Port Scanner application using Java By Syed M Hussain



Comment Added by : Rohit

Comment Added at : 2012-02-07 16:22:52

Comment on Tutorial : Simple Port Scanner application using Java By Syed M Hussain
Small modification.
System.out.println("Port not in use: " + i ); should be INSIDE the catch block. Otherwise, the output is like:

Port not in use: 79
Port in use: 80
Port not in use: 80
Port not in use: 81

Even if a Port is in use, it will print that its not in use.

Modified output

Port not in use: 79
Port in use: 80
Port not in use: 81
Port not in use: 82


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. It's very clear explanation. thank you
View Tutorial          By: miroot at 2012-12-27 17:46:14

2. plz can you help me,,,because i need this tomorrow
View Tutorial          By: ivie at 2012-12-12 11:20:35

3. This is not an easy example for begineer, please t
View Tutorial          By: Arif Islam Nayan at 2009-12-16 08:24:57

4. Could you please explain how to define our own val
View Tutorial          By: xxxxx at 2010-06-30 06:41:14

5. Great Article! Thanks
View Tutorial          By: Rachid at 2011-06-21 13:01:39

6. simple but accurate
View Tutorial          By: Githin Zacharia at 2011-08-10 06:08:32

7. it works well thanks
View Tutorial          By: Zahran at 2011-12-08 03:07:07

8. Enough to understand basic concept.Thanks.
View Tutorial          By: Jyothylakshmy P u at 2012-09-18 05:35:48

9. hey. How would i get the ClientLists displayed in
View Tutorial          By: andrew at 2009-07-24 14:10:24

10. if i want to write my gmail address how can i prov
View Tutorial          By: asmcn at 2011-12-27 19:40:49