In the tutorial, the goal of the piped command is to use grep to verify if the port number is in the output of netstat. Because n forces a numerical output, the port number is going to be shown, which is what is needed.
On the other hand, N forces a symbolic output. Therefore, if aNt is used instead of ant, all the “named” (i.e. standardized) port numbers such as 445, 139 and 631 are going to be replaced by their corresponding standardized names, i.e. microsoft-ds, netbios-ssn and ipp.
This won’t be a problem if you select a random port number (e.g. 4623) which doesn’t have a standardized name. In such case, both aNt and ant will show you the customized port number (despite of the hostname). But if you happen to pick a port number that has a standardized port name, aNt will not show you any output even though such customized port number is in use.