์๋
ํ์ธ์ ์ฌ๋ฌ๋ถ! ์ง๋ ๊ธ ์ ํด์ค์์ ์ฝ์๋๋ฆฐ ๋๋ก , ์ธํด์ญ ๋ฑ๋ก์ ์ํด ์ ์๊ฒ ๋ณด๋ด์ฃผ์ J2SE, JavaEE ํ
์คํธ ๊ณผ์ ๋ฅผ ๊ฒ์ํฉ๋๋ค. ์๋ฃํ๋ ๋ฐ 30๋ถ์ด ์ฃผ์ด์ง๋๋ค. ์ฌ์ค, ์ ๋ 14๋ฌธ์ ์ค 12๋ฌธ์ ๋ฅผ ๊ตฌํ์ต๋๋ค. - ์ฌ๋ฌ ๊ฐ์ง ๋ต๋ณ ์ต์
์ด ์์ ์ ์์์ ์๋ฏธํฉ๋๋ค. * ๋ต๋ณ ์ต์
์ด ํ๋๋ง ์์ ์ ์์์ ์๋ฏธํฉ๋๋ค.
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
- ์ง๋ฌธ
Integer a = new Integer(2); Integer b = new Integer(2); What code will provide output: "false"? Check all that apply. ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: - System.out.println(a.intValue() == b.intValue()); - System.out.println(a.compareTo(b)); - System.out.println(a.equals(b)); - System.out.println(a == b);
Which HTTP methods are NOT considered idempotent (multiple execution of query will give the same result)? (Choose all that apply) ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: - GET - POST - HEAD - PUT
How should servlet developers handle the HttpServlet's service() method when extending HttpServlet? (Choose all that apply). ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: - They should override the service() method in most cases. - They should call the service() method from doGet() or doPost(). - They should call the service() method from the init() method. - They should override at least one doXXX() method (such as doPost()).
Which methods are used by a servlet to handle form data from a client? (Choose all that apply) ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: - HttpServlet.doHead() - HttpServlet.doPost() - HttpServlet.doForm() - ServletRequest.doGet() - ServletRequest.doPost() - ServletRequest.doForm()
Given the Product Bean: public class Product{ public Product(String title, int size){ this.title = title; this.size = size; } String title; int size; } How would servlet code from a service method (e.g. doPost()) pass a Product bean info to the jsp? ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: * response.setAttribute("product", new Product("Shirt", t)); * response.setParameter("product", new Product("Shirt", t)); * request.setAttribute("product", new Product("Shirt", t)); * request.setParameter("product", new Product("Shirt", t));
You have to create your own type of exception, named UserOperationExัeption. And you need to make it a checked exัepetion. What is the appropriate signature in this case? Check all that apply. ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: - public class UserOperationExัeption extends RuntimeExัeption{...} - public class UserOperationExัeption extends Exัeption{...} - public class UserOperationExัeption extends IOExัeption{...} - public class UserOperationExัeption extends extends Error{...}
Given following classes hierarchy: public class Building {...} public class Warehouse extends Building {...} public class Shop extends Building {...} public class SportsShop extends Shop {...} and code: ... Building b1 = new Building(); Building b2 = new Warehouse(); ... What code will cause a ClassCastException to be thrown? Check all that apply. ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: - Warehouse w1 = b2; - Warehouse w2 = (Warehouse) b2; - Warehouse w3 = new SportsShop(); - Shop s1 = (Shop)b1; - Shop s2 = new SportsShop();
Given the method: public int shift(int value, int offset) { value += offset; return value; } What will be the output of following code: int v = 2; shift(v,5); System.out.println(v); ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: * 2 * 5 * 7 * 3
Given: public class Product { public Product(String title, int size){ this.title = title; this.size = size; } String title; int size; public String toString() { return title + ":" + size; } } ... Set products = new HashSet(); products.add(new Product("Hat", 3)); products.add(new Product("Hat", 3)); System.out.println(products); What items will be in the programm output, considering that Product class inherits equals() and hashCode() methods from Object? ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: * Hat * [Hat:3, Hat:3] * [Hat:3] * RuntimeException about duplicate elements
What code is valid for creating immutable list? ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: * List immutableItems = Collections.unmodifiableList(new ArrayList()); immutableItems.add("i1"); immutableItems.add("i2"); * List items = new ArrayList(); items.add("i1); items.add("i2"); List immutableItems = Collections.unmodifiableList(items); * List items = new ArrayList(); items.add("i1); items.add("i2"); final List immutableItems = items; * List can't be immutable
What is complexity (Big 0 notation) of ArrayList contains() method? ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: * 0(n^2) * 0(log(n)) * 0(n) * 0(1)
Given and array of size n, suppose you need to write a program that calculates the sum of every second element of this array. What will be the complexity (Big 0 notation) of most optimal implementation of this algorithm? ะะฐัะธะฐะฝัั ะพัะฒะตัะพะฒ: * 0(n^2) * 0(n/2) * 0(n) * 0(1)
GO TO FULL VERSION