connect()

This initiates a connection on a socket. Here is its syntax:

int connect(int fdsock, const struct sockaddr *addr,  socklen_t len);

Here, fdsock represents the file descriptor of the socket onto which the connection is desired, addr represents the structure that contains the address of the socket, and len represents the size of the structure addr that contains the address.