For this exercise a program is open a socket to localhost on port 256 and send the message "hello socket world" before closing the socket.

Catching any exceptions or errors is not required.




   coinsert'jsocket' [ require 'socket'             NB.  Sockets library
   socket =.  >{.sdcheck sdsocket''                 NB.  Open a socket
   host   =. sdcheck sdgethostbyname 'localhost'    NB.  Resolve host
   sdcheck sdconnect socket ; host ,< 256           NB.  Create connection to port 256
   sdcheck 'hello socket world' sdsend socket , 0   NB.  Send msg