将一个英文语句以单词为单位逆序排放。例如“I am a boy”,逆序排放后为“boy a am I” ...
句子逆序
http://www.nowcoder.com/questionTerminal/48b3cb4e3c694d9da5526e6255bb73c3
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String nextLine = scanner.nextLine();
String[] s = nextLine.split(" ");
for (int i = s.length - 1; i >= 0; i--) {
System.out.print(s[i] + " ");
}
}}

