Queue Collection in Java

Understanding Queue collection in Java with real life example

In this Queue Collection tutorial, we are going to learn what queue interface offers and how can we get best out of it using LinkedList and PriorityQueue concrete classes. The principle of Java Queue is the same as the queue we follow in real life. Suppose you are Lucas, standing in the middle of the Read more about Understanding Queue collection in Java with real life example[…]

String Operations

String

The String class represents character strings. All string literals in Java programs, such as,”abc” are implemented as instances of this class. Strings are constant; their values cannot be changed after they are created. String buffers support mutable strings. Because String objects are immutable they can be shared. Example

is equivalent to:

Read more about String Operations[…]

Operators in Java

Java provides a rich set of operators environment which are used to manipulate primitive data types. There are many types of operators in java which are given below: Arithmetic operators Unary Operators Assignment Operators Relational Operators Logical Operators Ternary Operators Bitwise Operators Instance of Operator[ps2id id=’Arithmetic’ target=”/] The Arithmetic Operators The Java programming language provides Read more about Operators in Java[…]

Understanding Queue collection in Java with real life example

In this Queue Collection tutorial, we are going to learn what queue interface offers and how can we get best out of it using LinkedList and PriorityQueue concrete classes. The principle of Java Queue is same as the queue we follow in real life. Suppose you are Lucas, standing in the middle of the queue Read more about Understanding Queue collection in Java with real life example[…]

Install OpenJDK 8 on Ubuntu 14.04 LTS

Step 1: Add the OpenJDK Team Personal Package Archive (PPA) Add the PPA:

Once, we run the above command you should be able to see the below message on the command interface. Step 2: The Installation The best practice is first to update our packages

Once, we run the above command you should Read more about Install OpenJDK 8 on Ubuntu 14.04 LTS[…]

Method Overloading v/s Method Overriding

The capability of more than one objects to respond to the same message in a different way can be broadly categorized into two types: Method Overloading and Method Overriding. METHOD OVERLOADING If we have methods with the same name but having different signatures or behaviors in the same scope than the methods are known as Read more about Method Overloading v/s Method Overriding[…]

Get the number of lines and characters in a file using Java

This example demonstrates one of the ways to find the number of lines and characters in a file using Java Programming Language Here is the block of code that will make the task easy for you

  The file named “file.txt” here in this example is located inside the folder named codedbug on drive Read more about Get the number of lines and characters in a file using Java[…]

Struts 2.x Netbeans IDE Setup

Struts 2.x is a powerful framework which is used to develop the variety of web applications. It is under the control and management of Apache organization and is available as open source. It provides an easy and effective way to develop web applications based on MVC pattern. It makes developers easy to work with Servlet Read more about Struts 2.x Netbeans IDE Setup[…]

Understanding Map collection in Java with real life example

Java Map, maps unique keys to values. A map cannot contain duplicate keys; each key can map to at most one value. For example, Starbucks. When you order something, you give them your name for them to know to whom the order belongs, right? Now let’s imagine you need to model the same thing in Read more about Understanding Map collection in Java with real life example[…]

Contact Us
close slider
Contact Us

How can we help you with?