Java Programe Structure Java class contains may classes but only one class contain main method. Class contain data members and methods that operate on the data members of the class. Method may contend data type declaration and executable statements. To write program, we first need to define classes and then put them together. A java may contain one or more sections. Document Section: The documentation section comprises a set of comment lines giving the name of programes, author details and other details of program. Comments must explain why and what are the cases. This will help in maintaining the program. For single line comment comment programer will use ' // ' forword slash and for multiline comment programer will use ' /* */ ' syntax. Package Statement: The first statement allowed in a java file is Package statement. This statement declares a package name and inform the compiler that class defined here belong to this package. For ex...
A blog about Java basic concept, Java Keywords, Algorithems, Loops, Conditional loops, Data Structure, Java collections, Database, OOPS concepts, Java Interface, Java String, Java Execption handling, Java Networking, Java AWT, Java Swing, Java Applet, Java JDBC, Java Multithreading, Java I/O, Java String, Java conversion, Java date. And we are going to explain every point in deep for better understanding.