-
public static void main(String[] args) – Java main method
In Java programs, the point from where the program starts its execution or simply the entry point of Java programs is the main() method. Why is the main method so important? The Java compiler or JVM looks for the main method when it starts executing a Java program. The signature of the main method needs to be in a specific…
-
oops scenario programs
Scenario #1: Expected Understanding: Access Modifiers, Single Inheritance, getter methods, Constructor Overloading 1) Create a Class named “Trainer” with main method. – Have default instance variables String dept, institute – Assign values – “Java”, “Payilagam” to them – Have private instance variable int salary – Assign 10000 as value for salary. – Create getter method…
-
sql (day2)
create database: example: create database students; Rename database: example: alter database “students” rename to “school”; Create database using primary key: given name for id – column name. serial – should be integer, it takes contiguous number at continuous manner. primary key – don’t repeat not null – compulsory to fill data. Moreover defaultely takes not…
-
System.out.println() in Java
What Is System Out Println in Java? To define System.out.println() in Java, it is a simple statement that prints any argument you pass and adds a new line after it. println() is responsible for printing the argument and printing a new line System.out refers to the standard output stream (System.out.println is a Java statement that…
-
Array and it types
Array: An array in Java is a group of like-typed variables referred to by a common name.To declare an array, define the variable type with square brackets . Following are some important points about Java arrays. In Java, all arrays are dynamically allocated. (discussed below) Arrays are stored in contagious memory [consecutive memory locations]. Since arrays are…
-
Flowchart
1.Palindrome: 2.Addiion of digits: 3.Count of digits: 4.Armstrong: 5.Decimal to binary: 6.Binary to decimal: 7.Prime number: 8.Least common multiple: 9.Greatest common divisor: 10.Fibonacci series: