Scanner scanner = new Scanner(new File("/Users/Rajkumar/Downloads/STM. Java Scanner class provides the nextLine() method to facilitates line by line of file’s content. Reader = new BufferedReader(new FileReader( We can read a file line by line in Java in two ways. The dog has its states such as color, name, breed, and behaviors such as barking, eating, wagging her tail. This is the reason why Java is not 100% object-oriented language.Įxample: A dog is an object of Animal class. If we work and achieve Company goals then obviously money would follow. Here, we have listed topic-wise frequently asked most important 850+ core java interview questions with the best possible answers. 'I would say that work is more important. 'Money is always important, but the work is most important for me.' Possible Answer 2. Ex : toString () 4) Method name must be combination of verb and noun. This frame of mind is good for you (at least at the time of interview). 3) If a method contains multiple words, every inner word should start with an uppercase letter. These primitive data types are not object oriented. Answer: 1) Method names should start with small letters. Java is not a pure Object Oriented Language because it supports primitive data type such as byte, boolean, char, double, float, int, long, short. It doesn’t occupy memory for each thread. The multithreading concept of Java shares a common memory area. Multithreaded: Java Multithreaded features allows us to write programs that can perform many tasks simultaneously.High Performance: Java enables high performance with the use of JIT (Just-In-Time) compilers.Secured: Java is well known for its security.Without any modifications, we can use a program on different platforms. Java is a write once, run anywhere language. Platform independent: Java is platform-independent.Portable: Java run time environment uses a bytecode verification process to make sure that code loaded over the network doesn’t violate Java security constraints.Object-Oriented: Java is an object-oriented programming language.Even though Java is based on C++, it was developed by eliminating poor programming practices of C++. Some of the features which play an important role in the popularity of java are as follows: The pressure to perform well in an interview can feel overwhelming.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |