Home
10th Grade
11th And 12th
11th Grade
12th Grade
3rd Grade
4th Grade
5th Grade
6th Grade
7th Grade
8th Grade
9th Grade
Advance Accountancy
Auditing
Computer Aptitude
Direct And Indirect Taxation
Exams
General Hindi
Indian Finance System
Information Technology And Application In Business
Macro Economics
Town Planning
Aerospace And Aeronautical
Analytical Instrumentation
Banking Awareness
Banking Exam
Biochemistry
Bioinformatics
Biology
Biotechnology
Business Statistics
C Program
C Programming
C++ Programming
Career Aptitude Test
Cell Biology
Central Superior Service (css)
Chemical Engineering
Chemistry
Civil Engineering
Commerce
Computer
Computer Fundamentals
Computer Science
Cost Accounting
Css
Database
Drug And Pharmaceutical Biotechnology
Ecat And Mcat Entry Test
Economics
Electrical Engineering
Electrical Engineering Questions
Electrical Measurement And Instrumentation
Engineering
English
English Literature
Environment Management
Environmental Biotechnology
Enzyme Technology
Financial Management And Financial Markets
Gate
General Knowledge
Graduate Assessment Test (gat)
Health And Physical
Heat Transfer
Html
Human Anatomy And Physiology
Human And Cultural Diversity
Human Resource Management
Ias
Indian Economy
Indian Economy
Indian General Awareness
Indian Geography
Indian Geography
Indian History
Indian History
Indian Polity
Instrumentation Transducers
International Relations
Java Program
Javascript
Judiciary And Law
Life Sciences
Management
Marketing And Marketing Management
Mass Transfer
Mechanical Engineering
Mechanics Of Materials
Medical Subjects
Microbiology
Networking
Php
Placement Tests
Professional Communication
Quantitative Aptitude
Reasoning Aptitude
Renewable Energy
Science
Sociology
Sql
Surveying
Total Quality Management
Uidai Aadhaar Supervisor Certification
Virology
Notificatin
Exam
Blog
Contact Us
Sockets(Computer Science > Javascript ) Questions and Answers
Home
Topic
Computer Science
Javascript
Sockets
Question 1.
Which of the following is a stateless protocol?
HTML
XHTML
HTTP
All of the mentioned
Explanation:-
Answer: Option C. ->
HTTP
Question 2.
What does the value 2 of the WebSocket attribute Socket.readyState indicate?
Closed connection
Handshake connection
Unestablished connection
Established connection and communication is possible
Explanation:-
Answer: Option B. ->
Handshake connection
Question 3.
How many WebSocket events are available?
2
3
4
5
Explanation:-
Answer: Option C. ->
4
Question 4.
Which method is used to close the WebSocket?
Socket.flush()
Socket.close()
Socket.Close()
Socket.dispose()
Explanation:-
Answer: Option B. ->
Socket.close()
Question 5.
How does the client and the server communicate following the rules defined by the WebSocket protocol?
Long-lived TCP Socket
Short-lived TCP Socket
UDP Socket
HTTP Socket
Explanation:-
Answer: Option A. ->
Long-lived TCP Socket
Question 6.
Which of the following are not a socket property?
onopen
readyState
onmessage
ready
Explanation:-
Answer: Option D. ->
ready
Question 7.
How can we check the subprotocol being used by the client?
subprotocol property
protocol property
clientprotocol property
none of the mentioned
Explanation:-
Answer: Option B. ->
protocol property
Question 8.
How will you transmit data using the connection?
send(data)
Socket.send(“data”)
Socket.send(data)
Socket(data)
Explanation:-
Answer: Option C. ->
Socket.send(data)
Question 9.
Which of the following is not a WebSocket event?
open
close
error
deny
Explanation:-
Answer: Option D. ->
deny
Question 10.
What does an History object contain?
URL
Parameters
Attribute values
Property
Explanation:-
Answer: Option A. ->
URL
1
2
3
4
5
6
7
Next →
One click Login
Login With Google
Old way of Login
Login With Email