Java Lecture 1

Java Lecture 1

Brief Introduction

  1. Was introduced by Sun MicroSystems.
  2. Was Very famous as soon as it was launched.
  3. Microsoft wanted to take over Java and then launched C#.
  4. C# has many new functionalities. The problem with c# is it works only on dotnet.
  5. Later on Java copied more features from C #.
  6. It is the most structured Language.Hence it is easy to read as compared to others. languages, it is self-explanatory.
  7. The current version of Java is Java19.

Fundamentals Of Computer

  1. Processor is the heat of the computer.
  2. This will only understand 1 or 0.
  3. This 1 or 0 language is also called machine-level language.
  4. But it is very difficult to remember hence we used assembly language.
  5. But the processor will only understand 1 and 0 that is why we used an assembler to convert assembly language programs to machine code.
  6. But again writing assembly language is still difficult.
  7. Hence we came up with something called high-level language.
  8. The high language again cannot be understood by the processor.
  9. Hence we use a compiler that will convert the high-level language to machine-level code.
  10. Drawback of a compiler is that once code is converted into machine-level language then it becomes platform-dependent.
  11. But we know that java is platform-independent.
  12. Hence to solve this issue we use a seperate compiler called as java compiler.
  13. The java compiler will convert the code into byte code and not machine-level language.
  14. Always remember we use the RAM and not the HDD hence always have your program.
  15. This byte code is then given to the Java Virtual Machine which will convert it into machine - level code.
  16. In java we have the java compiler which acts as the compiler and the java virtual machine which will acts as the interpreter, hence java is both interpreted and compiled language.
  17. The role of the interpreter is to convert it into machine language.