About 53 results
Open links in new tab
  1. Java - Convert integer to string - Stack Overflow

    int i = 1234; String str = Integer.toString(i); Returns a String object representing the specified integer. The argument is converted to signed decimal representation and returned as a string, …

  2. How do I convert a String to an int in Java? - Stack Overflow

    Alternatively, you can use an Ints method from the Guava library, which in combination with Java 8's Optional, makes for a powerful and concise way to convert a string into an int:

  3. java - How do I convert from int to String? - Stack Overflow

    Nov 5, 2010 · If you say ""+i, Java creates a StringBuilder object, appends an empty string to it, converts the integer to a string, appends this to the StringBuilder, then converts the …

  4. java - What is the most efficient way to convert an int to a String ...

    May 31, 2017 · The first two examples are actually identical, since String.valueOf (int) uses the Integer.toString (int) method. The third is ugly, and probably less efficient since concatenation …

  5. java - Integer to String conversion methods - Stack Overflow

    Sep 27, 2010 · String oneAsString = "1"; int one = Integer.parseInt(oneAsString); There is also a page in the Sun Java tutorial called Converting between Numbers and Strings.

  6. Integer.toString (int i) vs String.valueOf (int i) in Java

    Feb 2, 2023 · I am wondering why the method String.valueOf(int i) exists ? I am using this method to convert int into String and just discovered the Integer.toString(int i) method. After looking the …

  7. ¿Cómo convertir un String en Int en Java? [duplicada]

    ¿Cómo convertir un String en Int en Java? [duplicada] Formulada hace 8 años y 8 meses Modificada hace 8 años y 8 meses Vista 216k veces

  8. Guia definitiva de conversión de tipos en Java - Stack Overflow en ...

    Para hacer la siguiente operación necesitaremos hacer uso de la clase Integer y de su método "parseInt" de la siguiente manera: String numCadena = "1"; int numEntero = …

  9. How to concatenate int values in java? - Stack Overflow

    Apr 20, 2010 · I have the following values: int a=1; int b=0; int c=2; int d=2; int e=1; How do i concatenate these values so that i end up with a String that is 10221; please note that …

  10. java - Как перевести int в String? - Stack Overflow на русском

    Feb 21, 2021 · Как перевести int в String? Вопрос задан 11 лет 9 месяцев назад Изменён 4 года 11 месяцев назад Просмотрен 51k раза