About 51,100,000 results
Open links in new tab
  1. How to Return a String in Java - Delft Stack

    Feb 2, 2024 · This example illustrates a straightforward yet effective use of StringBuilder for string manipulation in Java, showcasing a common practice employed by developers to efficiently build and …

  2. Returning String Methods in Java? - Stack Overflow

    This is related to the return statement. When something says return x (for any value of x), it is saying to terminate the current method call and yield the value x to whoever called the method.

  3. Java String Methods - GeeksforGeeks

    Oct 11, 2025 · In Java, a String represents a sequence of characters used for storing and manipulating text. It is immutable and provides many built-in methods for operations like concatenation, …

  4. How to Return Strings Using String Methods in Java?

    Learn how to effectively return strings from string methods in Java with expert examples and common coding mistakes.

  5. Understanding String Return in Java - javaspring.net

    Nov 12, 2025 · String return in Java allows a method to send a string value back to the calling code, enabling data transfer and manipulation. This blog post will explore the fundamental concepts, usage …

  6. How to Return a String in Java: A Comprehensive Guide

    Oct 23, 2023 · Returning String values from methods is a vital skill for any Java developer. In this extensive tutorial, we will dig deep into the various ways to return Strings in Java.

  7. Java String Reference - W3Schools

    The String class has a set of built-in methods that you can use on strings. Returns the number of Unicode values found in a string. Compares two strings. Returns true if the strings are equal, and …

  8. String (Java Platform SE 8 ) - Oracle Help Center

    The class String includes methods for examining individual characters of the sequence, for comparing strings, for searching strings, for extracting substrings, and for creating a copy of a string with all …

  9. function to return a string in java - Stack Overflow

    In Java, a String is a reference to an immutable object. This, coupled with garbage collection, takes care of much of the potential complexity: you can simply pass a String around without worrying that it …

  10. Object toString () Method in Java - GeeksforGeeks

    Apr 4, 2025 · We typically do use the toString () method to get the string representation of an object. It is very important and readers should be aware that whenever we try to print the object reference, then …