Is it possible to write JAVA program without including any of the packages,such as "import java.io.*"; bcoz I instantly wrote a code without "import..." statement and runned the program on command Line & it worked. the code is: class Person { String name; int age; Person(String s,int a) { name = s; age = a; } accept() { System.out.println(name+"Hi!!!!!"); System.out.println(age); } } class Demo { public static void main(Strings args[])throws IOException { String name = args[0]; int age = Integer.parseInt(args[1]); Person p = new Person(name,age); p.accept(); } }
3 47081) There are 10 different threads in runnable state. Each having priority 1 to 10. How does the CPU schedules or executes these threads?
RBS,
2 64632) Suppose there are 5 directories having lot of files (say txt files) in each directory. 2 things :- 2.1) You want to search for filenames which have a particular pattern. 2.2) Out of these filtered files you want to search for a particular keyword or a search string. How can you achieve this?
20363) Suppose you are a very rich person, having 50 rooms and you have lost the key for one of the room's. How effectively you can find this key? (Qs2 and Qs3 are related)
RBS,
3 8274Suppose there is a System A which gives some output. This output is used as input by system B. The rate at which System A produces is faster than the rate at which system B consumes it. How can you improve this?
RBS,
1 5371Suppose there is an Online shopping cart application having different objects like Cart, SelectionItem, Billing, COnfiguration, Authentication, Authorization, PersonalDetails etc. Out of this which one can be made a singleton pattern and why?
RBS,
2 102107) Suppose there is Student class like class student { int age; string name; } We want to store these objects in a HashMap. Do we need to override any methods in Student class? If any which ones and why? what if i just override equals or just hashcode? what will be the results in both the cases?
4 8272
does java support pointers?
What are nested classes in java?
what is the purpose of the wait(), notify(), and notifyall() methods? : Java thread
how to one war file class to another war file class?
Difference between static binding and dynamic binding?
List some important features of java 10 release?
What are inbuilt functions in java?
What are exceptions
What is the main method java?
How variables are stored in memory?
What is java developer skills?
Can an unreferenced object be referenced again?
Does the order of public and static declaration matter in main method?
What is the final class modifier?
What about member inner classes?