Java

Thread Life Cycle in Java - Thread States in Java — step-by-step Programming tutorial on Progressive Robot

Thread Life Cycle in Java – Thread States in Java

URL: https://www.progressiverobot.com/thread-life-cycle-in-java-thread-states-in-java/ Understanding Thread Life Cycle in Java and Thread States are very important when you are working with Threads and programming for multithreaded environment. From our last tutorial, we can create a [java thread](/community/tutorials/java-thread-example "Java Thread Example – Extending Thread Class and Implementing Runnable Interface") class by implementing Runnable interface or by extending Thread […]

Read more
How to Merge Two Lists in Java? — step-by-step Programming tutorial on Progressive Robot

How to Merge Two Lists in Java?

URL: https://www.progressiverobot.com/merge-two-lists-in-java/ Merging two lists in Java is often a useful operation. These lists can be ArrayLists or LinkedLists. How to Merge Two Lists in Java There are multiple ways we can merge two lists in Java. Let's explore some of the straightforward ones to get your job done! 1. The addAll() method to merge […]

Read more
Java String Copy — step-by-step Programming tutorial on Progressive Robot

Java String Copy

URL: https://www.progressiverobot.com/java-string-copy/ Sometime back I was asked how to copy a String in java. As we know that [String](/community/tutorials/java-string) is an [immutable](/community/tutorials/how-to-create-immutable-class-in-java) object, so we can just assign one string to another for copying it. If the original string value will change, it will not change the value of new String because of immutability. Java […]

Read more
Java 8 Stream - Java Stream — step-by-step Programming tutorial on Progressive Robot

Java 8 Stream – Java Stream

URL: https://www.progressiverobot.com/java-8-stream/ Welcome to Java 8 Stream API tutorial. In the last few java 8 posts, we looked into [Java 8 Interface Changes](/community/tutorials/java-8-interface-changes-static-method-default-method "Java 8 Interface Changes – static methods, default methods, functional Interfaces") and [Functional Interfaces and Lambda Expressions](/community/tutorials/java-8-functional-interfaces "Java 8 Lambda Expressions and Functional Interfaces Example Tutorial"). Today we will look into one […]

Read more
Command Line Arguments in Java — step-by-step Programming tutorial on Progressive Robot

Command Line Arguments in Java

Command-line arguments in Java are used to pass arguments to the main program. If you look at the [Java main method](/community/tutorials/public-static-void-main-string-args-java-main-method) syntax, it accepts [String array](/community/tutorials/java-string-array) as an argument. When we pass command-line arguments, they are treated as strings and passed to the main function in the string array argument. The arguments have to be […]

Read more
CHAT