SCJP Questions And Answers

Home| Forums | Join Google Group | Join Yahoo Group | Jobs
Get custom programming done at GetAFreelancer.com!
Earn Money
  Trading Forex Online
  Paramount Airways
  Free Data Recovery
 Cargo
 Job Portal
  HSBC Investment
 Management
 Cheap Web Hosting
  Make Trip
  Cheap Air Travel
 Leisure Hotel
  Free Air Travel
  Mutual Fund Informations
   Cheapest Cellular Plan
 Free Sexy Indians
  Call Center Software
  Hot Indian
Programming Help | Homework Help | Counseling
Astrology Advice | Tarot Advice | Parenting
Dating Advice | Love Advice | Divorce Advice
Legal Advice | Debt Advice | Career Advice
- 48 - 1. public class foo {
2. static String s;
3. public static void main (String[]args) {
4. system.out.printIn ("s=" + s);
5. }
6. }

What is the result?
A. The code compiles and "s=" is printed. B. The code compiles and "s=null" is printed. C. The code does not compile because string s is not initialized. D. The code does not compile because string s cannot be referenced. E. The code compiles, but a NullPointerException is thrown when toString is called.
Answer: B



QUESTION NO: 91
Which two valid declarations of a char? (Choose Two)

A. Char ch = "a"; B. Char ch = `\' `; C. Char ch = `cafe'; D. Char ch = "cafe"; E. Char ch = `\ucafe'; F. Char ch = `\u10100'; G. Char ch = (char) true;

Answer: B, E



QUESTION NO: 92
Given:

1. String foo = "blue";
2. Boolean[]bar = new Boolean [1];
3. if (bar[0]) {
4. foo = "green";
5. }
Earn Money
  Trading Forex Online
  Paramount Airways
  Free Data Recovery
 Cargo
 Job Portal
  HSBC Investment
 Management
 Cheap Web Hosting
  Make Trip
  Cheap Air Travel
 Leisure Hotel
  Free Air Travel
  Mutual Fund Informations
   Cheapest Cellular Plan
 Free Sexy Indians
  Call Center Software
  Hot Indian