JAVA 17

COEP
Lets Crack Online Exam

IT Interview Exam Questions: JAVA 17 (IT Campus Placement)

Subject: JAVA 17

Part 17: List for questions and answers of JAVA

 

Q1. Which of these interface abstractes the output of messages from httpd?

a) LogMessage

b) LogResponse

c) Httpdserver

d) httpdResponse

 

Q2. Which of these class is used to create servers that listen for either local or remote client programs?

a) httpServer

b) ServerSockets

c) MimeHeader

d) HttpResponse

 

Q3. Which of these is a standard for communicating multimedia content over email?

a) http

b) https

c) Mime

d) httpd

 

Q4. Which of these methods is used to make raw MIME formatted string?

a) parse()

b) toString()

c) getString()

d) parseString()

 

Q5. Which of these class is used for operating on request from the client to the server?

a) http

b) httpDecoder

c) httpConnection

d) httpd

 

Q6. Which of these method of MimeHeader is used to return the string equivalent of the values stores on MimeHeader?

a) string()

b) toString()

c) convertString()

d) getString() 

 

Q7. What is the output of this program?

class networking {

        public static void main(String[] args) throws Exception {

            URL obj = new URL(“http://www.coep.in/javamcq”);

            URLConnection obj1 = obj.openConnection();

            System.out.print(obj1.getContentType());

        }

    }

a) html

b) text

c) html/text

d) text/html

 

Q8. Which of these is an instance variable of class httpd?

a) port

b) cache

c) log

d) All of the mentioned

 

Q9. Which of these is an instance variable of httpd that is a Hashtable?

a) port

b) cache

c) log

d) stopFlag

 

Q10. Which layer of OSI reference model is responsible for decomposition of messages and generation of sequence numbers to ensure correct re-composition from end to end of the network?

a) Physical

b) Data-link

c) Transport

d) Application

 

Q11. Which of these is a protocol for breaking and sending packets to an address across a network?

a) TCIP/IP

b) DNS

c) Socket

d) Proxy Server

 

Q12. How many ports of TCP/IP are reserved for specific protocols?

a) 10

b) 1024

c) 2048

d) 512 

 

Q13. How many bits are in a single IP address?

a) 8

b) 16

c) 32

d) 64

 

Q14. Which of these is a full form of DNS?

a) Data Network Service

b) Data Name Service

c) Domain Network Service

d) Domian Name Service

 

Q15. Which of these class is used to encapsulate IP address and DNS?

a) DatagramPacket

b) URL

c) InetAddress

d) ContentHandler

 

Q16. Process of creating exact copy of the existing object is called

a) cloning

b) overloading

c) overriding

d) coping

 

Q17. Which is the predefined package

a) Lang package

b) io package

c) util package

d) All of above

 

Q18. Java intermediate code is known as

a) First code

b) Mid code

c) Byte code

d) None of above

 

Q19. Which command is used for interpretation of java program

a) Java

b) javac

c) javap

d) none of above 

 

Q20. What is meaning of jar

a) java archived

b) java array

c) java architecture

d) none of these

 

Part 17: List for questions and answers of JAVA

 

Q1. Answer: a

 

Q2. Answer: b

 

Q3. Answer: c

 

Q4. Answer: a

 

Q5. Answer: d

 

Q6. Answer: b

 

Q7. Answer: d

 

Q8. Answer: d

 

Q9. Answer: c

 

Q10. Answer: c

 

Q11. Answer: a

 

Q12. Answer: b

 

Q13. Answer: c

 

Q14. Answer: d

 

Q15. Answer: c

 

Q16. Answer: a

 

Q17. Answer: b

 

Q18. Answer: c

 

Q19. Answer: a

 

Q20. Answer: a