this port scanner uses a socket to initiate a TCP connection to the IP Address and iterates over the port range provided.
g++ main.cpp -o main
./main
./main 192.168.1.1 1000
Scanning ports for 192.168.1.1...
Port 53 is open
Port 80 is open
Port 443 is open
Scan complete