![](https://img-blog.csdnimg.cn/20201014180756754.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java
xiaoyu雨
这个作者很懒,什么都没留下…
展开
-
String的字符串倒叙
字符串的倒叙第一种public class Str { public static void main(String[] args) { //定义一个字符串 String str = "asdfgh"; //利用String类的toCharArray(),再倒序输出数组的方法 char[] a = str.toCharArray(); //遍历 for (int i...原创 2019-03-21 09:59:50 · 527 阅读 · 0 评论 -
String从字符串中取出数字
从字符串中取出数字第一种public class Text { public static void main(String[] args) { // 定义一个字符串 String str = "ab12cd34sd56"; // 用java的内部类 str = str.trim(); String str2 = ""; // 判断字符串不等于空 if (st...原创 2019-03-21 10:17:01 · 12338 阅读 · 0 评论