You are on page 1of 2

Hetauda School of Management and Social Sciences

First Terminal Examination - 2078


Sixth Semester / BCA / CACS 355: Network Programming
Roll No: Name: Time - 20 Minutes.
Group A
Attempt all [10 x 1 = 10]
Q1) One of the following applications of the Client and Server Model?
a) Email c) WWW
b) Network printing d) All of these.
Q2) Which of the following is not the method to create the object of InetAddress class.
a) InetAddress.getByName("www.hsm.edu.np"); c) new InetAddress(“www.hsm.edu.np”)
b) InetAddress.getAllByName("www.hsm.edu.np"); d) InetAddress.getLocalHost()
Q3) The NetworkInterface class is not used to..
a) Represent local IP address c) Enumerate all the local address
b) Create Virtual Interfaces d) Create InetAddress objects
Q4) A generic URI tells ..
a) What a resource is c) How to get the resource
b) Where a resource is d) All of the above
Q5) in URL syntax protocol://userInfo@host:port/path?query#fragment, the query indicates
a) Arguments to the server c) Where the resource is.
b) Part of file to be accessed d) Type of resource
Q6) The URL class is inside the package.
a) java.io c) java.net
b) java.net.url d) java.url
Q7) …………is not a HTTP method.
a) GET c) DELETE
b) SET d) POST
Q8) …. Is the code for %
a) %% c) %25
b) %20 d) %&
Q9) Is not a type of proxy.
a) DIRECT c) HTTP
b) SOCKS d) INDIRECT
Q10) Which is not a server-side program?
e) Servlets g) PHP pages
f) Applets h) CGIs
Hetauda School of Management and Social Sciences
First Terminal Examination - 2078
Sixth Semester / BCA / CACS 355: Network Programming

F.M. - 60
P.M. - 24
Group B Time - 3 Hrs.

Attempt any Six [6 x 5 = 30]

Q 1) What do you understand by client server architecture? How java can be used to implement the client server
model?
Q 2) Explain about “InetAddress” Class. Explain three of its methods with prototype.
Q 3) Why is URL Class used? Explain Relative URL and parts of URL with syntax.
Q 4) What is URL Encoding? Why do we need this? Explain with a program that encodes any URL.
Q 5) Write a program to read data from URL.
Q 6) Write about four HTTP Methods.
Q 7) What is the use of NetworkInterface class? Explain the Basic Features of NetworkInterface Class.

Group C

Attempt any Six [2 x 10 = 20]

Q 8) What is RMI? Explain stub and skeleton. Write a program that invokes remote method which will check
whether a user given number is prime or composite.
Q 9) Implement InetAddress class to write a program that checks spams.
Q 10) Write a chat application using TCP client and server socket.

You might also like