What two items must be given to the socket function in order to create a socket object? A) The socket type that will be used. B) The socket port that will be used. C) The IP address to be used. D) The socket family that will be used.

Respuesta :

Answer:

The correct option are:-

a) The socket type that will be used

d) The socket family that will be used  

Explanation:

The socket() method generates the unbound socket in a networking domain and returns a descriptor of the register, which can be used in subsequent socket function calls.

The socket() method takes three arguments:  

Domain:- The domain for which a socket is to be built is defined.

Type:- The socket type to be generated is defined.

Protocol:- It specifies a common socket protocol to use. The protocol setting of 0 causes socket() to use a default uninstalled protocol that is suitable for the socket type requested.