File Handling in Java

File Handling in Java

File Handling in Java, Java Input and Output operations, handling text files, create a file, read a file, write a file, and compare two files. File Handling in Java permits us to create, read, update, and delete the files, which are stored on the local file system. File (Text File) Handling in Java User Point … Read more

User Defined Methods in Java

Built in Methods in Java

User-Defined Methods in Java, Java Static and Non-static methods, Java method with return a value, and java method without return a value. Java Built-in methods – String methods, Array methods, Number methods, and character methods. User Defined Methods in Java i) Introduction to Java Methods ii) Types of Methods iii) User defined Methods ———————————– i) … Read more

Arrays in Java

Arrays in Java

Arrays in Java, What is Array in Java, Declare Arrays, Java Array built-in methods, advantages of Java Arrays, and Drawbacks of Java Arrays. Java Arrays • In Java, Array is an Object that holds a fixed number of values of a single data type • The length of the Array is established when the Array is … Read more

Java ArrayList

Java ArrayList

Java ArrayList, create ArrayList, add elements to ArrayList, return ArrayList size, remove elements of ArrayList, and clear all elements of the ArrayList. Java Array is Static Data Structure and ArrayList is Dynamic Data Structure Array versus ArrayList in Java Array is Static (its size is fixed), ArrayList is Dynamic…. Java Array Example: int [] a= … Read more

Java Strings

Java Strings

Java Strings, What is String?, Declare Strings in Java, String handling in Java, String Methods, String Concatenation, and String Comparison. Strings in Java are objects, and they are immutable. Whenever a change to a String is made, an entirely new String is created. String Handling in Java What is String? The string is a sequence of characters … Read more

Java Branching Statements

Java Branching Statements

Java Branching Statements, Java Programming Fundamentals, Java Control Flow, Java break, Java continue, and Java return statements. We have three types of conditional statements in computer programming: I. Decision-making/Conditional statements (if, switch) II. Loop Statements (for, while, do while, and enhanced for) III. Branching statements (break, continue, and return) Branching Statements in Java Branching statements … Read more

Java Loop Statements

Java Loop Statements

Java Loop Statements, Java Control Flow, Java for loop, while loop, do while loop, enhanced for loop, and Java nested loop statements. Looping in programming languages is a feature that facilitates the execution of a set of instructions/functions repeatedly while some condition evaluates to true. Loop Statements in Java We have four loop structures in … Read more

Java Decision Making Statements

Java Decision Making Statements

Java Control Flow, Java Decision Making Statements, Java if statement, Java else statement, Java nested conditions, and Java Switch case statement. Control Flow Statements in Java We have three types of conditional statements in computer programming. 1. Decision-making/Conditional statements (if, switch) 2. Loop Statements (for, while, do while, and enhanced for) 3. Branching statements (break, … Read more

Access and Non Access Modifiers in Java

Access and Non Access Modifiers in Java

Access and Non Access Modifiers in Java, Java public modifier, Java private modifier, Java default modifier, and Java static modifier. Modifiers in Java Java provides a rich set of modifiers. They are used to control access mechanisms and also provide information about class functionalities to JVM. Java has two categories of modifiers: 1. Access Modifiers … Read more

Comments in Java

Comments in Java

Comments in Java, writing comments in programs, single-line comments, multi-line comments, and Java documentation comments. Programming Comments are English words used for code readability and code documentation. Java Comments 1. Purpose of Comments The Java comments are the statements that are not executed by the compiler and interpreter. The comments can be used to provide … Read more