BeginnersBook

  • Home
  • Java
    • Java OOPs
    • Java Collections
    • Java Examples
  • C
    • C Examples
  • C++
    • C++ Examples
  • DBMS
  • Computer Network
  • Python
    • Python Examples
  • More…
    • jQuery
    • Kotlin
    • WordPress
    • SEO
    • JSON
    • JSP
    • JSTL
    • Servlet
    • MongoDB
    • XML
    • Perl

Java For-each Loop (Enhanced for loop)

Last Updated: June 2, 2024 by Chaitanya Singh | Filed Under: java

In this guide, we will discuss for-each loop in detail with the help of examples. In Java, the for-each loop is used to iterate arrays… [Read More]

Tags: Collections

Search Element in Doubly Linked List in Java

Last Updated: May 23, 2024 by Chaitanya Singh | Filed Under: java

In this tutorial, we will learn how to write a Java program to search an element in doubly linked list. Java Program to search an… [Read More]

Tags: Collections, Java-LinkedList

How to Insert an item in Doubly LinkedList in Java

Last Updated: May 23, 2024 by Chaitanya Singh | Filed Under: java

In this tutorial, we will learn how to insert an item in Doubly LinkedList in java at various positions. We will write a Java Program… [Read More]

Tags: Collections, Java-LinkedList

Convert Integer List to int Array in Java

Last Updated: September 23, 2022 by Chaitanya Singh | Filed Under: java

In this guide, we will see how to convert Integer List to int Array in Java. There are several ways, you can do this conversion,… [Read More]

Tags: Collections, Java-Array

Convert a Set of String to a comma separated String in Java

Last Updated: September 23, 2022 by Chaitanya Singh | Filed Under: java

Problem description: We have given a Set that contains String elements. Our task is to convert this set of string to a comma separated string… [Read More]

Tags: Collections, Java-Strings

How to Convert ArrayList to HashSet in Java

Last Updated: September 23, 2022 by Chaitanya Singh | Filed Under: java

There are several ways to convert ArrayList to HashSet. In this guide, we will discuss the following ways with examples: Passing ArrayList to constructor of… [Read More]

Tags: Collections, Java-ArrayList, Java-HashSet

Convert Comma Separated String to HashSet in Java

Last Updated: September 22, 2022 by Chaitanya Singh | Filed Under: java

In this guide, we will discuss, how to convert a comma separated string to HashSet in Java. We will be using the String split() method… [Read More]

Tags: Collections, Java-HashSet, Java-Strings

When to use ArrayList and LinkedList in Java

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

In this guide, we will discuss, when to use ArrayList and when to use LinkedList in Java. There are multiple similarities between these classes. However… [Read More]

Tags: Collections, Java-ArrayList

How to Increase the capacity of ArrayList

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

When we create an ArrayList in Java, it is created with a default capacity of 10. However an ArrayList can be automatically resized if more… [Read More]

Tags: Collections, Java-ArrayList

Perform Binary Search on ArrayList in Java

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

In this tutorial, you will learn how to perform binary search on ArrayList in Java. 1. Perform binary search on ArrayList using Collections.binarySearch() In this… [Read More]

Tags: Collections, Java-ArrayList

Add Multiple Items to an ArrayList in Java

Last Updated: December 1, 2024 by Chaitanya Singh | Filed Under: java

In this tutorial, you will learn how to add multiple items to an ArrayList in Java. 1. Add multiple items using adAll() method The addAll()… [Read More]

Tags: Collections, Java-ArrayList

Difference between Array and ArrayList

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

In this guide, we will discuss the difference between Array and ArrayList. What is an Array? An array is a collection of elements of similar… [Read More]

Tags: Collections, Java-Array, Java-ArrayList

Difference between length of Array and size of ArrayList in Java

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

In this tutorial, you will learn the difference between length of Array and size of ArrayList in Java.. Length of Array: // creating an array… [Read More]

Tags: Collections, Java-Array, Java-ArrayList

How to make an ArrayList read only in Java

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

A read only ArrayList means that no modification operations is allowed to be performed on ArrayList. This list cannot be modified by adding, removing or… [Read More]

Tags: Collections, Java-ArrayList

Deque Interface in Java Collections

Last Updated: September 11, 2022 by Chaitanya Singh | Filed Under: java

Deque is a Queue in which you can add and remove elements from both sides. In the Java Queue tutorial we have seen that the… [Read More]

Tags: Collections

  • 1
  • 2
  • 3
  • …
  • 11
  • Next Page »

Java Tutorial

Java Introduction

  • Java Index
  • Java Introduction
  • History of Java
  • Features of Java
  • C++ vs Java
  • JDK vs JRE vs JVM
  • JVM - Java Virtual Machine
  • First Java Program
  • Variables
  • Data Types
  • Operators

Java Flow Control

  • Java If-else
  • Java Switch-Case
  • Java For loop
  • Java while loop
  • Java do-while loop
  • Continue statement
  • break statement

Java Arrays

  • Java Arrays

OOPs Concepts

  • OOPs Concepts
  • Constructor
  • Java String
  • Static keyword
  • Inheritance
  • Types of inheritance
  • Aggregation
  • Association
  • Super Keyword
  • Method overloading
  • Method overriding
  • Overloading vs Overriding
  • Polymorphism
  • Types of polymorphism
  • Static and dynamic binding
  • Abstract class and methods
  • Interface
  • Abstract class vs interface
  • Encapsulation
  • Packages
  • Access modifiers
  • Garbage Collection
  • Inner classes
  • Static import
  • Static constructor

Java Exception Handling

  • Exception handling
  • Java try-catch
  • Java throw
  • Java throws
  • Checked and Unchecked Exceptions
  • Jav try catch finally
  • Exception Examples
  • Exception Propagation

Collections Framework

  • Collections in Java
  • Java ArrayList
  • Java LinkedList
  • Java Vector
  • Java HashSet
  • Java LinkedHashSet
  • Java TreeSet
  • Java HashMap
  • Java TreeMap
  • Java LinkedHashMap
  • Java Queue
  • Java PriorityQueue
  • Java Deque
  • Comparable interface
  • Comparator interface
  • Collections Interview Questions

MORE ...

  • Java Scanner Class
  • Java 8 Features
  • Java 9 Features
  • Java Conversion
  • Java Date
  • Java Multithreading
  • Java I/O
  • Java Serialization
  • Java Regex
  • Java AWT
  • Java Swing
  • Java Enum
  • Java Annotations
  • Java main method
  • Java Interview Q

Copyright © 2012 – 2025 BeginnersBook . Privacy Policy . Sitemap