SUPERSTARWEBTECH

There is no elevator to success. You have to take the stairs. Take your first steps with SSWT!

CS506 Web Design & Development Quiz MCQs Lecture 23-45 FinalTerm Objective Questions

CS506-Web Design & Development Quiz  MCQS #Objective #Questions #Finalterm

1. Which of the following interface needs to implement while creating threads?

  • Serializable
  • Runnable ✔
  • ActionListener
  • WindowListener

2. From the following which code can be used to create session object in the Servlet

  • HttpSession session=req.getSession(true);
  • HttpSession session=req.getSession(false);
  • HttpSession session=req.getSession(1);
  • HttpSession session=req.setSession(1); ✔

3. Servlet mapping is defined in ___.

  • servlet
  • web.xml ✔
  • html
  • JSP

4. “application” is a object of:

  • ServletContext ✔
  • HttpSession
  • ServletConfig
  • Both b and c

5. To  provide global control of JSP we use following tag:

  • <%@ %> ✔
  • <%–   %>
  • <%!   %>
  • <%=   %>

6. Which of the following statement is correct to assign maximum priority to thread “t2”?

  • t2.setPriority(Thread.PRIORITY_MiX)
  • t2.setPriority(Thread.PRIORITY_MAX)
  • t2.setPriority(Thread.MAX_PRIORITY) ✔
  • t2.setPriority(Thread.MIN_PRIORITY)

7. Which of the following range of response code indicates that request was successful?

  • 100-199
  • 200-299 ✔
  • 300-399
  • 400-499

8. From the following methods, which method cannot be overridden in the JSP page

  • _jspService() ✔
  • jspDestroy()
  • jspInit()
  • both b and c

9. Which of the following problem occurs with lower priority threads?

  • Race condition
  • Starvation ✔
  • Average waiting time
  • Process death

10. Packages are the way to organize files into different ___ according to their functionality, usability as well as the category they should belong to.

  • Directories ✔
  • Folders
  • Libraries
  • both b and c

11. From the following tags, which one is the Special JSP tag?

  • <jsp: …. />
  • <%! %>
  • <%= %>
  • <%@ %>

12. From following methods; which method is not a part of the JSP life cycle?

  • jspInit()
  • jspService
  • _jspService()
  • jspDestroy()

13. getId() returns the unique ID of

  • Current session
  • Previous Session
  • Next session
  • Both b and c

14. Client is reffered as  a

  • Computer user
  • Computer that a person is using for communication purpose
  • Person which carry out web surfing
  • None

15. Which of the following method allows any other thread of the same priority to execute?

  • sleep()
  • wait()
  • notify()
  • yield()

16. JSP scripting elements is/are

  • Declarations
  • Scriptlets
  • expressions
  • All of these

Author

Anam Afzal

Anam Afzal

Hi, I'm a Pakistani freelancer with a passion for helping businesses achieve their online goals through no-code solutions. I specialize in WordPress customization and ManyChat automation, and I'm always on the lookout for new ways to use technology to make businesses more efficient and successful. I'm also a big believer in the power of no-code tools to democratize technology and make it accessible to everyone. I'm passionate about sharing my knowledge and helping others learn how to use no-code tools to create their own websites, automate their workflows, and grow their businesses. If you're looking for a reliable and experienced no-code developer, I'm here to help. Please feel free to contact me to discuss your project requirements.
SHARE THIS POST