← Bitkernel Interview Insights
The answer is D and I did get it right, but for the wrong reason at first.
Evaluate each statement against fundamental socket programming concepts, focusing on the OSI model and socket API specifications. Identify the incorrect statement by recalling that stream and datagram sockets are distinct types and cannot directly communicate with each other. Then, briefly explain why the other statements are correct to demonstrate comprehensive understanding.
Pro tip: When answering, not only identify the incorrect statement but also explain the practical implications, such as why mixing socket types would require an application-level gateway. This shows depth beyond textbook knowledge.
Read the question carefully to identify that it asks for the incorrect statement among four options related to socket programming.
Analyze each option: (A) true, as communication requires at least two sockets; (B) true, sockets in different domains cannot communicate directly; (C) false, as there are more than two socket types (e.g., raw sockets); (D) false, as stream and datagram sockets cannot communicate directly.
Determine that both (C) and (D) are incorrect, but if forced to choose one, (D) is the most clearly incorrect because it contradicts the fundamental distinction between socket types.
Provide a concise explanation for why the chosen statement is incorrect, referencing socket types and communication domains.
If time permits, give a brief example, such as TCP (stream) and UDP (datagram) sockets cannot directly exchange data without an intermediary.
AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.