Skip to main content

Java - Introduction to Programming| OOPS concept

 Java - Introduction to Programming

Lecture 1




Installation & First Program


  1. Install Java

a. Install JDK (https://www.oracle.com/in/java/technologies/javase-downloads.html)

b. Install IntelliJ (https://www.jetbrains.com/idea/download/#section=mac)

OR

b. Install Visual Studio Code (VS Code) - Prefer THIS (https://code.visualstudio.com/download)




  1. Sample Code

Functions

A function is a block of code which takes some input, performs some operations and returns some output. 

The functions stored inside classes are called methods.

The function we have used is called main.


Class

A class is a group of objects which have common properties. A class can have some properties and functions (called methods).

The class we have used is Main.


  1. Our 1st Program


public class Main {


   public static void main(String[] args) {

  // Our 1st Program

       System.out.println("Hello World");

   }

}


                                    Java is a programming language that is used to create software applications.

Java is a programming language that is used to create software applications. Java also has one of the largest installed bases of all programming languages, and its use can be found in many different domains.

Java installation varies depending on your operating system and what version of Java you are installing.

Java is a programming language that was designed to be easy to learn. It is one of the most popular languages in use today. Java is typically used for applications that need a robust, cross-platform environment, such as desktop apps and web apps.

Java code can be compiled into bytecode or interpreted at runtime by a Java Virtual Machine (JVM). It can also be used with other languages like C++, Python or Ruby in an IDE like Eclipse or Netbeans.

Java is a programming language and computing platform. Java is mainly used for developing desktop, web applications, enterprise software, and mobile applications.

Java was originally designed to work on the end-user's computer. But now it can also be used to deploy Java programs on a wide variety of devices like smart TVs, set-top boxes, printers, Blu-ray players and more.

Developers use Java to create cross-platform applications that can be executed on any device that supports Java without the need for recompilation.


Others link:-

Amazon link:-

Comments

Popular posts from this blog

Enter 3 numbers from the user & make a function to print their average in java, c++, python, java.

Enter 3 numbers from the user & make a function to print their average. To find the average of three numbers, you need to add the three numbers together and then divide the sum by three. Here's how you can write a function in C++, C, Python, and Java to take three numbers from the user and calculate their average: JAVA import java . util .*; public class Solutions {     public static void main ( String args []) {        Scanner sc = new Scanner ( System . in );        int a = sc . nextInt ();        int b = sc . nextInt ();        int c = sc . nextInt ();          int average = ( a + b + c ) / 3 ;        System . out . println ( average );    }    }   C++: // c++ #include <iostream> using namespace std ;...

2D Arrays | Java Complete Placement Course | Lecture 11

Java - Introduction to Programming Lecture 11 2D Arrays In Java It is similar to 2D matrices that we studied in 11th and 12th class. Creating a 2D Array - with new keyword int [][] marks = new int [ 3 ][ 3 ] ; Taking a matrix as an input and printing its elements. import java . util .*;   public class TwoDArrays {     public static void main ( String args []) {         Scanner sc = new Scanner ( System . in );         int rows = sc . nextInt ();         int cols = sc . nextInt ();           int [][] numbers = new int [ rows ][ cols ];           //input         //rows         for ( int i = 0 ; i < rows ; i ++) {             //columns  ...

Merge Sort | How do I learn merge sort?

       Merge Sort | For Beginners | Java Placement Course >> Merge sort is a popular sorting algorithm that utilizes a divide-and-conquer approach to sort elements in an array. The basic idea behind merge sort is to divide an unsorted array into two halves, recursively sort each half, and then merge the two sorted halves into a single sorted array. >>  Merge sort algorithm works by recursively dividing an array into two halves, sorting each half, and then merging them to obtain the sorted array. The basic steps of the merge sort algorithm are as follows: Divide the unsorted array into two halves, mid and left. Sort the left half recursively using merge sort algorithm. Sort the right half recursively using merge sort algorithm. Merge the two sorted halves to obtain the final sorted array. JAVA Implementation: // Merge sort public class MergeSort {     //time complexity=nlogn     public static void conquer ( int arr [], int ...