Showing posts sorted by relevance for query java-8-stringjoiner-example-how-to-join-String. Sort by date Show all posts
Showing posts sorted by relevance for query java-8-stringjoiner-example-how-to-join-String. Sort by date Show all posts

Friday, November 8, 2019

Java Eight Stringjoiner Illustration - How To Bring Together Multiple Strings Amongst Delimiter Inwards Java

While everyone was looking at the lambda expression as well as Stream API, JDK quietly sneaked some of the exciting methods on its API. There are a lot of hidden gems on JDK 8 as well as I accept uncovered many of them already inwards this weblog as well as today we'll utter close 1 of such gems which y'all tin sack utilisation inwards your twenty-four hr menstruum to twenty-four hr menstruum programming activities similar joining much String together. The Java 8 has added a novel shape called StringJoiner to bring together Strings. The java.util.StringJoiner tin sack move used to bring together whatever release of arbitrary String, a listing of String, or an array of String inwards Java. You tin sack pick out whatever delimiter to bring together String similar comma, pipe, colon or semi-colon. This shape too allow y'all to specify a prefix as well as suffix piece joining ii or to a greater extent than String inwards Java.


In gild to bring together Strings, y'all showtime exercise an instance of StringJoiner class. While creating the instance, y'all provide the delimiter, a String or character, which volition move used betwixt Strings piece joining them similar y'all tin sack overstep comma equally a delimiter to exercise a comma separated String or piping to exercise a piping delimited String.

In this article, y'all volition run into some examples of StringJoiner to acquire how to bring together String inwards Java 8.

Some of the readers may move curious why exercise y'all demand a novel StringJoiner shape if y'all already accept StringBuffer as well as StringBuilder classes to concatenate String, which is nil but joining.

Well, y'all tin sack for sure utilisation the StringBuffer as well as StringBuilder shape to bring together String inwards Java as well as that's what Java developers exercise prior to Java 8

But, StringJoiner provides much cleaner as well as capable interface to join Strings. You don't demand to write logic to start adding comma solely later the showtime chemical factor as well as non to add together later the final element, which Java programmers used to exercise piece joining String inwards Java vi or JDK 7.

Though StringJoiner is simply 1 of the hidden gems of Java SE 8 release, at that spot are many to a greater extent than twenty-four hr menstruum to twenty-four hr menstruum useful features which are hidden behind lambda expressions as well as streams like CompletableFuture. You tin sack farther see Java, C++, Python, as well as Ruby to shape a comma-separated String.

// Creating a StringJoiner amongst delimiter equally comma StringJoiner joiner = new StringJoiner(","); joiner.add("Java"); joiner.add("C++"); joiner.add("Python"); joiner.add("Ruby");  String text = joiner.toString(); System.out.println("comma separated String: " + text);  Output comma separated String: Java,C++,Python,Ruby

You tin sack run into that StringJoiner has joined all String y'all accept added to it. You don't demand to loop through a listing of String anymore.

This code may hold off really similar to the code y'all may accept written using StringBuffer but StringJoiner is really dissimilar from StringJoiner.

In instance of StringBuffer or StringBuilder, y'all demand to explicitly telephone phone the append(",") to bring together String past times a comma but, here, in 1 lawsuit y'all country StringJoiner close delimiter y'all are done.

No demand to telephone phone whatever business office or write exceptional logic, except adding String.

You tin sack farther shorten the to a higher house code inwards 1 draw of piece of occupation because StringJoiner allows fluent API equally shown below:

String CSV = new StringJoiner(",").add("Scala").add("Haskell").add("Lisp").toString(); System.out.println("CSV: " + CSV);  Output CSV: Scala,Haskell,Lisp
You tin sack run into how y'all tin sack bring together multiple String inwards simply 1 draw of piece of occupation using StringJoiner as well as fluent API. If y'all are novel to fluent API as well as interested inwards writing your own, y'all should check Fluent API Design - Influenza A virus subtype H5N1 Crash Course on Udemy which talks about a software architecture approach for creating readable, intuitive, as well as easy-to-understand code.

 JDK quietly sneaked some of the exciting methods on its API Java 8 StringJoiner Example - How to bring together multiple Strings amongst delimiter inwards Java

You tin sack too provide prefix as well as suffix String to StringJoiner which tin sack move used to enclose String similar past times giving parenthesis equally prefix as well as suffix y'all tin sack enclose String equally shown inwards our tertiary instance below:

String text = novel StringJoiner(",", "(", ")")                   .add("Car Insurance")                   .add("Health Insurance")                   .add("Life Insurance").toString(); System.out.println("Insurance: " + text);           Output Insurance: (Car Insurance,Health Insurance,Life Insurance)

You tin sack run into inwards this example, nosotros accept enclosed the comma-separated String amongst an opening as well as closing braces past times supplying them equally prefix as well as suffix.

One of the mutual utilisation cases of this characteristic is dynamically generating IP address equally shown inwards our 4th instance below:

String text = new StringJoiner(".", "[", "]")                 .add("192")                 .add("168")                 .add("2")                 .add("81").toString(); System.out.println("IP address: " + text);  Output IP address: [192.168.2.81]

You tin sack run into the squeamish as well as build clean IP address generated past times supplying opening as well as closing bracket equally prefix as well as suffix as well as dot equally separator.  To move honest, these are simply tip of the iceberg inwards damage of both StringJoiner as well as Java 8 features.

I propose y'all hold off a comprehensive Java course of didactics like The Complete Java MasterClass which covers almost everything close Java SE 8. This volition allow y'all to become the sum exercise goodness of novel API enhancement as well as Java 8 features inwards your twenty-four hr menstruum to twenty-four hr menstruum programming.

 JDK quietly sneaked some of the exciting methods on its API Java 8 StringJoiner Example - How to bring together multiple Strings amongst delimiter inwards Java



That's all close how to utilisation StringJoiner inwards Java 8 to Join multiple Strings. There is some other alternative, y'all tin sack utilisation String.join() equally good to bring together String. It internally uses StringJoiner for joining String but it's to a greater extent than versatile equally it provides some other overloaded version of String.join() to bring together elements from a String array or listing of String.

Further Learning
The Complete Java MasterClass
Java SE 8 for Really Impatient
courses)
  • 5 Books to Learn Java 8 Better? (read here)
  • Java 8 Interview Questions as well as Answers (questions)
  • Java 8 String Documentation (docs)
  • Difference betwixt Stream.map() as well as Stream.flatMap() inwards Java 8? (answer)
  • 10 Examples of converting a List to Map inwards Java 8 (see here)
  • Java 8 Comparator Example (check here)
  • Collection of best Java 8 tutorials (click here)
  • 10 Examples of Stream inwards Java 8 (example)
  • Difference betwixt abstract shape as well as interface inwards Java 8? (answer)
  • How to form the may past times values inwards Java 8? (example)
  • How to format/parse the appointment amongst LocalDateTime inwards Java 8? (tutorial)
  • Top five Course to principal Java 8 Programming (courses)
  • Thanks for reading this article thence far. If y'all similar this Java 8 filter method tutorial thence delight part amongst your friends as well as colleagues. If y'all accept whatever questions or feedback thence delight drib a note.

    P.S.: If y'all simply desire to acquire to a greater extent than close novel features inwards Java 8 thence delight run into the course What's New inwards Java 8. It explains all the of import features of Java 8 e.g. lambda expressions, streams, functional interfaces, Optional, novel Date Time API as well as other miscellaneous changes.

    How Bring Together Multiple String Into 1 Inwards Coffee Eight - String.Join() Example

    I possess got been writing nearly novel features of Java SE 8 from quite a sometime. Initially, my focus areas on much talked nearly lambda expressions together with streams, but piece of cake I realized that Java 8 is non simply nearly them, it's much to a greater extent than than that. It has many to a greater extent than novel features together with API enhancements which volition assistance Java developers inwards their day-to-day project equally much equally lambdas together with streams. One of such less talked characteristic is the powerfulness to bring together multiple String objects into 1 separated alongside whatsoever delimiter. It has added a shape called StringJoiner inwards the java.util bundle which nosotros possess got seen earlier, but it has equally good added a novel method on String class, the join() method, which finally allows you lot to bring together Strings inwards Java.

    You mightiness possess got faced scenarios inwards past times where you lot possess got a listing of String or an array of String together with you lot desire to bring together them past times a comma.

    Unfortunately, Java didn't possess got anything similar Android's TextUtils.join() or JavaScript's Array.join() method which tin bring together String on a delimiter.

    Finally, the hold back is over. JDK 8 has introduced a join() method which you lot tin exercise to bring together whatsoever pose out of arbitrary String, an array of String or a listing of String past times a delimiter.

    Similar to String.split(), it is equally good a static method together with you lot tin telephone telephone it equally String.join(). It has 2 overloaded versions, 1 accepts a delimiter together with pose out of String objects equally variable arguments together with other accepts a delimiter together with an Iterable to bring together elements from array together with list.

    In this article, I'll exhibit you lot a duet of examples of how to exercise join() method of String shape to bring together Strings inwards Java 8 together with you lot tin ever await dorsum to a proficient Java course of education like The Complete Java MasterClass to sympathise to a greater extent than nearly these picayune gems from Java 8.

    It's 1 of the best course of education to acquire Java together with equally good most up-to-date, latterly updated for Java eleven version.




    How to bring together Mulitple String Objects inwards Java 8

    You tin exercise the String.join() method to bring together a pose out of String literals, String objects, String elements from an array, or String elements from List, Set or whatsoever collection because it accepts an Iterable.

    This agency all classes which implement this interface tin exercise this join() method to bring together private objects. You tin equally good overstep the delimiter of your choices similar a comma, semicolon, pipe, or colon characters.

    Here is an instance of String.join() to bring together String literals by PIPE character

    String banks = String.join("|", "Citibank", "Bank of America", "Chase"); System.out.println("banks: " + banks);  Output banks: Citibank|Bank of America|Chase
    You tin come across that the terminal String contains all 3 String literals separated past times PIPE delimiter.

    hither is some other instance to bring together all elements of a List by commas

    List<String> payCompanies = Arrays.asList("Apple pay", "Samsung Pay", "Paypal"); String wallats = String.join(",", payCompanies); System.out.println("electronic wallats : " + wallats);  Output electronic wallets : Apple pay,Samsung Pay,Paypal

    together with hither is the lastly instance of String.join() to bring together elements of an array inwards Java:

    String[] typesOfCards = {"Credit card", "Debit card", "Master Card"}; String cards = String.join(",", typesOfCards ); System.out.println("cards: " + cards);  Output cards: Credit card,Debit card,Master Card

    You tin come across that the terminal String is a combination of all the private String together with they are separated past times a comma. This is actually handy together with you lot destination upward using quite often. Btw, if you lot desire to know to a greater extent than nearly such gems from Java 8 unloose thence I equally good advise you lot join split, thence you lot tin straight telephone telephone them on String literal or simply overstep the String values you lot desire to join.  The plan contains 3 examples, starting fourth dimension to bring together arbitrary String literals, 2nd to bring together elements from the listing of String, together with 3rd to bring together elements from an array.

    package test;  import java.util.Arrays;  /**  * Java Program to demonstrate how to exercise StringJoiner together with String.join)( method  * to bring together private String together with String shape listing together with array.  */ public class Test {    public static void main(String[] args) {      // Joining arbitrary pose out of String     String combined = String.join(" together with ", "LinkedIn", "Microsoft");     System.out.println("string joined past times together with : " + combined);      // joining elements from a listing of String     String joined = String         .join("|", Arrays.asList("Java", "Android", "Oracle"));     System.out.println("String joined past times pipage from listing : " + joined);      // joining String elements of an array     String[] biggies = { "Apple", "Google", "Amazon" };     String fromArray = String.join(",", biggies);     System.out.println("String joined past times comma from array: " + fromArray);    }  }  Output string joined past times and : LinkedIn and Microsoft String joined past times pipage from list : Java|Android|Oracle String joined past times comma from array: Apple,Google,Amazon


    That's all nearly how to exercise String.join() method inwards Java 8 to bring together String. Now, no demand to exercise whatsoever 3rd political party library e.g. Google Guava or Apache commons, you lot tin bring together String past times simply using JDK itself. If you lot come upward across whatsoever other item about String.join() method, delight allow us know. It's 1 of the interesting methods which volition live shortly equally pop as String.split() is at the moment.


    Further Learning
    The Complete Java MasterClass
    Java SE 8 for Really Impatient
    courses)
  • How to exercise forEach() method inwards Java 8 (example)
  • 10 Examples of Stream inwards Java 8 (example)
  • 5 Books to Learn Java 8 from Scratch (books)
  • How to convert List to Map inwards Java 8 (solution)
  • Difference betwixt abstract shape together with interface inwards Java 8? (answer)
  • 10 Free Courses for Experienced Java Programmers (courses)
  • How to kind the may past times values inwards Java 8? (example)
  • How to format/parse the appointment alongside LocalDateTime inwards Java 8? (tutorial)
  • 20 Examples of Date together with Time inwards Java 8 (tutorial)
  • Top five Course to original Java 8 Programming (courses)
  • Java 8 Interview Questions together with Answers (questions)

    Thanks for reading this article thence far. If you lot similar this Java 8 tutorial thence delight part alongside your friends together with colleagues. If you lot possess got whatsoever questions or feedback thence delight drib a note.

    P.S.: If you lot simply desire to acquire to a greater extent than nearly novel features inwards Java 8 thence delight come across the course What's New inwards Java 8. It explains all the of import features of Java 8 e.g. lambda expressions, streams, functional interfaces, Optional, novel Date Time API together with other miscellaneous changes.

    Thursday, October 31, 2019

    How To Convert A Listing Or Laid Upwardly Of String To Comma Separated String (Csv) Inward Coffee 8

    Before Java 8, it was non straightforward to convert a listing of String to a comma-separated String. You induce got to loop through the collection or listing in addition to bring together them manually using String concatenation, which tin convey upward to a greater extent than than four lines of code. Of course, you lot could encapsulate that into your ain utility method in addition to you lot should but JDK didn't render anything useful for such a mutual operation. Btw, things induce got changed. From Java 8 onwards you lot tin practise this easily. JDK 8 has provided a utility degree called StringJoiner every bit good every bit added a join() method into String degree to convert a List, Set, Collection or fifty-fifty array of String objects to a comma separated String inwards Java.

    This method accepts a delimiter in addition to an Iterable which contains String. Since all Collection classes implement Iterable, it's possible to bring together all String from a List or Set using a delimiter similar a comma, colon, or fifty-fifty space.

    Btw, similar most of the things, you lot demand to know unopen to pocket-size details. For example, if your List or Set contains goose egg thus a "null" string volition travel added into in conclusion String, thus delight beware of that. If you lot don't desire null, it's improve to remove whatsoever nulls earlier joining strings from the list.

    By the way, Java 8 is total of such splendid features which are oftentimes acquire ignored inwards the limelight of lambda expression, Stream API, novel Date Time API, in addition to other pregnant features.

    If you lot are interested to larn to a greater extent than close such splendid features, I propose you lot acquire through The Complete Java Masterclass on Udemy, i of the comprehensive class to larn Java. It is also most up-to-date in addition to lately updated for Java 11.





    1. List of String to Comma Separated String inwards Java

    Here is an event of converting a listing in addition to laid upward to a comma-separated String inwards Java 8:

    package tool;  import java.util.Arrays; import java.util.HashSet; import java.util.List; import java.util.Set;  /** *  * Influenza A virus subtype H5N1 unproblematic Java Program to to take away duplicates from Stream inwards Java 8 * This event uses Stream.distinct() method to remove * duplicates.  */ public class Hello {  public static void main(String args[]) {  List<String> books = Arrays.asList("Effective Java", "Clean Code",  "Java Concurrency inwards Practice"); System.out.println(books);  String bookString = String.join(",", books); System.out.println(bookString);  Set<String> authors = new HashSet<>(Arrays.asList("Josh Bloch", "Uncle Bob Martin",  "Brian Goetz")); System.out.println(authors);  String authorString = String.join(",", books); System.out.println(authorString);   } }  Output [Effective Java, Clean Code, Java Concurrency inwards Practice] Effective Java,Clean Code,Java Concurrency inwards Practice [Josh Bloch, Uncle Bob Martin, Brian Goetz] Effective Java,Clean Code,Java Concurrency inwards Practice


    You tin run across that if you lot conduct impress the listing or set, all the elements are written within a bracket. Since nosotros simply demand a CSV or comma-separated String, nosotros demand to purpose the String.join() method, in addition to that's what nosotros induce got done inwards this example.

    The lines:

    String bookString = String.join(",", books);

    and

    String authorString = String.join(",", books);

    Are the 2 lines which are doing all the function of joining all String from the listing in addition to laid upward into i separated yesteryear a comma. If you lot want, you lot tin alter the delimiter to colon or infinite to practise a unlike String based upon your requirement.

    By the way, Java 8 is total of such hidden features which are oftentimes acquire ignored inwards the limelight of lambda expression, Stream API, in addition to other major features. If you lot are interested to larn to a greater extent than close novel Java 8 features, I propose you lot acquire through ArrayList, LinkedList, Vector, HashSet, TreeSet, LinkedHashSet, etc.

    4. The String.join() is a static method, thus you lot don't demand a String object to telephone vociferation upward this one.


    That's all close how to convert a listing of String to a comma-separated String inwards Java. There are many ways to consummate this task, but every bit I said, prefer String.join() if you lot are using Java 8 or higher version. You tin also alter the delimiter to whatsoever grapheme or String you lot want. For example, if your String is separated yesteryear a colon instead of a comma, thus you lot tin simply purpose a colon, in addition to it volition function similar this. Just beware of goose egg though.

    Further Learning
    The Complete Java Masterclass
    5 Free Java 8 in addition to Java ix Courses for Developers
  • How to practise Map Reduce inwards Java 8?
  • 10 examples of the forEach() method inwards Java 8?
  • How to purpose flatMap inwards Java 8?
  • 10 examples of converting a List<V> to Map of <K, V> inwards Java 8?
  • Beginning Java 8 Language Features yesteryear Kishori Sharan
  • Top v Books to Learn Java 8 Better
  • 3 ways to read a file work yesteryear work inwards Java 8
  • 10 DevOps Courses for Java Developers
  • 5 Free Data Structure in addition to Algorithms Courses for Programmers

  • Thanks for reading this article thus far. If you lot similar this article, thus delight portion it amongst your friends in addition to colleagues. If you lot induce got whatsoever questions or feedback, thus delight drib a note.

    Saturday, November 23, 2019

    5 Departure Betwixt Stringbuffer, Stringbuilder Together With String Inward Java

    Though all 3 classes StringBuffer, StringBuilder and String are used for representing text information inward Java at that spot are roughly meaning differences betwixt them. One of the most notable differences betwixt StringBuilder, StringBuffer, together with String inward Java is that both StringBuffer together with StrinBuilder are Mutable class but String is Immutable inward Java. What this way is, you lot tin terminate add, take away or supervene upon characters from StringBuffer together with StringBuilder object but whatever modify on String object e.g. converting working capital to lowercase or appending a novel grapheme using String concatenation volition ever consequence inward a novel String object. Another key deviation betwixt them is that both StringBuffer together with String are thread-safe but StringBuilder is non thread-safe inward Java. String achieves its thread-safety from Immutability but StringBuffer achieves it via synchronization, which is likewise the principal deviation betwixt the StringBuffer together with StringBuilder inward Java.



    String vs StringBuffer inward Java

    One of the oldest inquiry from Java interviews are What is the deviation betwixt String together with StringBuffer, it's been asked from ages, I estimate started every bit presently every bit Java was released inward the 90s. Let's commencement respond this inquiry together with thence nosotros volition accept a await at rather novel StringBuilder vs String together with StringBuffer vs StringBuilder questions.

    1) First together with firstly deviation betwixt String together with StringBuffer is that onetime is Immutable land afterward is mutable. This way if you lot demand to manipulate String information thence roll it within a StringBuffer to avoid creating lots of modest together with temporary String objects together with putting describe per unit of measurement area on Garbage collector.

    2) Even though both StringBuffer together with String are thread-safe, String achieves its thread-safety yesteryear using Immutability land StringBuffer achieves it yesteryear synchronizing methods which modify the the world e.g. append(), delete() etc.


    By the way, apart from to a higher house differences, both String together with StringBuffer likewise has roughly key similarities e.g. both stand upwards for text data, both are defined inward java.lang package, both classes exists inward JDK from the commencement liberate together with both are thread-safe inward Java.

    Here is likewise a dainty diagram to highlight the mutable together with immutable deviation betwixt String together with StringBuffer inward Java:

     are used for representing text information inward Java at that spot are roughly meaning differences betwee five Difference betwixt StringBuffer, StringBuilder together with String inward Java



    StringBuffer vs StringBuilder inward Java

    One of the follow-up questions of the deviation betwixt String together with StringBuffer shape is the deviation betwixt StringBuilder vs StringBuffer. That's why it's non plenty to know exclusively close StringBuffer together with String, you lot must likewise know close its closed cousin StringBuilder which was added every bit a drop-in replacement of StringBuffer inward Java 1.5 release.

    If you lot await at the code of StringBuilder.java shape inward JDK, you lot volition realize that it's but StringBuffer without synchronized keyword, fifty-fifty comments together with description of methods are same. Anyway, let's run into roughly quick deviation betwixt StringBuffer together with StringBuilder shape inward Java:

    1) The most of import deviation betwixt StringBuffer together with StringBuilder is that onetime is thread-safe together with afterward is not. Why? because all key methods of StringBuffer are synchronized, which was afterward removed land creating StringBuilder class.

    2) Due to to a higher house property, their functioning is likewise different. StringBuilder is much faster than StringBuffer. Since they are generally used every bit local variables to manipulate String together with non actually shared betwixt multiple threads, it's improve to purpose StringBuilder inward house of, StringBuffer.

    Btw, apart from to a higher house differences they are likewise quite similar e.g. both StringBuffer together with StringBuilder stand upwards for mutable String together with both allow you lot to append together with delete characters. If you lot desire to larn to a greater extent than deviation betwixt them, delight read Java: Influenza A virus subtype H5N1 Beginner's Guide yesteryear Herbert Schildt, i of the adept books to larn Java fundamentals similar this.

     are used for representing text information inward Java at that spot are roughly meaning differences betwee five Difference betwixt StringBuffer, StringBuilder together with String inward Java





    When to purpose the String, StringBuffer, together with StringBuilder inward Java

    Now that you lot know the deviation betwixt these 3 similar classes, its fourth dimension to purpose that cognition together with brand a determination close when to purpose each of them.

    1) Use String if you lot demand text information which is relatively constant e.g. names, config parameters etc.

    2) Use StringBuilder if are doing lots of String concatenation e.g. you lot are generating dynamic String yesteryear using programming logic.

    3) Use StringBuffer when your String manipulation code is probable to hold out executed yesteryear multiple threads together with you lot are sharing the instance of same StringBuffer. It's highly unlikely together with if you lot are doing roughly but halt doing it together with purpose StringBuiler inward place.

    That's all close the deviation betwixt String, StringBuilder, together with StringBuffer inward Java. Just recall that String is immutable inward Java which way whatever change inward String volition alway provide inward novel String e.g. converting into upper or lower instance or getting substring out of it. Key deviation betwixt String together with StringBuffer is mutability. So, if you lot desire to concatenate multiple String it's improve to purpose StringBuffer than String.

    Similarly, the key deviation betwixt StringBuilder together with StringBuffer  is thread-safety together with speed, since StirngBuffer is thread-safe it's slower than StringBuilder. This is likewise i of the best coding exercise inward Java, if you lot desire to larn to see Java Coding Guidelines: 75 Recommendations for Reliable together with Secure Programs, i of the must read for both intermediate together with experienced Java developers.

     are used for representing text information inward Java at that spot are roughly meaning differences betwee five Difference betwixt StringBuffer, StringBuilder together with String inward Java



    Other Java String tutorials you lot may similar to explore
    • How to do an array from ArrayList of String inward Java? (solution)
    • How to separate a String yesteryear comma inward Java? (example)
    • The deviation betwixt String literal together with new() String inward Java? (answer)
    • How to bring together String inward Java using StringJoiner? (example)
    • How to purpose Regular Expression to Search inward String? (answer)
    • How to read a text file every bit String inward Java? (tutorial)
    • How to supervene upon characters on String inward Java? (solution)
    • How to detect if String is Empty inward Java? (answer)
    • How to count a release of Vowels together with Consonants inward Java String? (solution)
    • The deviation betwixt String together with StringBuffer inward Java? (answer)
    • The deviation between StringBuilder and StringBuffer in Java? (answer)
    • How to convert an array to String inward Java? (solution)
    • How to purpose substring method inward Java? (example)
    • How to purpose String.join() method inward Java 8? (example)
    • How to convert Enumeration type to String inward Java? (answer)
    • The best way to compare 2 Strings inward Java? (answer)
    • How to opposite String inward house inward Java? (answer)

    Further Learning
    Data Structures together with Algorithms: Deep Dive Using Java
    Java Fundamentals: The Java Language
    Complete Java Masterclass