Created
May 11, 2018 13:50
-
-
Save PandyYang/7bfc45f63c1e34ae6483f8d4dfe44c72 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cn.insist; | |
/** | |
* 将基本数据类型转化成字符类型的三种方式 | |
* 基本数据类型直接与""相连接即可 | |
* 调用String的value方法 | |
* 调用包装类中的toString方法 | |
* @author Pandy | |
* @date 2018/5/11 21:45 | |
*/ | |
public class Demo89783 { | |
public static void main(String[] args) { | |
System.out.println(34+"232232"); | |
System.out.println(String.valueOf(6666)); | |
System.out.println(Integer.toString(54544)); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment