![]() |
| Home | Tech FAQ | Interview Questions | Placement Papers | Tech Articles | Learn | Freelance Projects | Online Testing | Geeks Talk | Job Postings | Knowledge Base | Site Search | Add/Ask Question |
![]() Related Questions A (non-local) inner class may be declared as public, protected, private, static, final, orabstract. Latest Answer : An inner class is a full pledged member of the enclosing class (outer class), so it can be marked with any access modifier including abstract or final modifiers(neer both abstract and final together). But an inner class cannot contain any static members ... A package statement must appear as the first line in a source code file (excluding blanklines and comments). Latest Answer : package statement must appear as the first line in a source code file and one public class declaration. ... The readLine() method returns null when it has reached the end of a file. Latest Answer : readLine() method of BufferReader class returns String and when it reaches the end of file file it returns null. ... The default value of an String type is null. Latest Answer : We use overriding when method avaliable in super class doesnot satisfyour requirement.That is To extend the alreadyavailable feature wew use overloading.If we require the new functionality other than, what we already have we go for Overriding. ... The finally clause is used to provide the capability to execute code no matter whether ornot an exception is thrown or caught. Latest Answer : In try,catch clauses either try clause(If exception is not happend) or catch clause(If exception occures) is exicuted.If we want to exicute a block of statements doesn't depend on exception then we put those block of statements in finally ... A program's main() method takes an argument of the String[] type. Latest Answer : you write public static void main(String args[])so the argument type isstring and whatever input you give asjava abs "asd" 1then all the 3 arguments are stored int he corresponding string format in the args array and if you write for(int ... A Java source code file takes the name of a public class or interface that is defined withinthe file. A source code file may contain at most one public class or interface. If a publicclass or interface The read() method returns -1 when it has reached the end of a file. Latest Answer : It returns null value if its a char type and -1 if its a byte type. ... String objects are constants. StringBuffer objects are not. Latest Answer : see the following line of codeclass abc{ public static void main(String args[]) { String ab=new String("test");ab.replaceFirst("e","b");System.out.println(ab); }}guess what the result be No it will not replace e with b .Thats ... An object's lock is a mechanism that is used by multiple threads to obtain synchronizedaccess to the object. A thread may execute a synchronized method of an object only afterit has acquired the object's
Sponsored Links
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||