undefined123456 / test

我的第一个仓库

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

package test; /**

  • 第三题
  • 单词颠倒顺序输出
  • @author 王海玲1

*/ public class Test3 { public static void main(String[] args) { String str="how are you"; String[] strs=str.split(" "); for(int i=0;i<strs.length;i++){ System.out.print(strs[i]+" "); } System.out.println(); for(int i=strs.length-1;i>=0;i--){ System.out.print(strs[i]+" "); } }

About

我的第一个仓库


Languages

Language:Java 100.0%