Checked and Unchecked Exceptions in Java

There are two types of exceptions in Java i.e. checked and unchecked exceptions. Below I have explained about these two exceptions with examples. Checked and Unchecked Exceptions in Java Checked Exceptions Those exceptions that are checked at compilation time are called checked exceptions. Checked exception includes the classes that extend Throwable class except RuntimeException and …

Checked and Unchecked Exceptions in Java Read More »

How to Connect Java (JDBC) with MySQL or Oracle Database

In this tutorial you will learn how to connect java (jdbc) with mysql or oracle database. Java JDBC is an API used to connect with database and perform all database related operations.   There are few steps for connecting java with any database. 1. Register Driver Class 2. Create Connection 3. Execute Queries 4. Close Connection   …

How to Connect Java (JDBC) with MySQL or Oracle Database Read More »

Difference between Array and ArrayList in Java

Here you will learn about difference between array and arraylist in java. Both array and arraylist are most important and frequently used data structure in java. Below I have discussed about various differences between them.   Difference between Array and ArrayList in Java Property Array ArrayList Size Array is fixed in size. Once declared, its …

Difference between Array and ArrayList in Java Read More »

How to Split String in Java with Example

Here you will learn how to split string in java. We can split string in Java using split() method of java.lang.String class. It takes a regular expression as an argument and returns an array of strings. Syntax:

  Split String in Java Example Below program will split the string by space.

  Output …

How to Split String in Java with Example Read More »