Home > Back-end >  "Ace and Fire" how to put the string before and after the order
"Ace and Fire" how to put the string before and after the order

Time:01-12

String STR="Ace and Fire";
String [] alstr=STR. The split (" ");
StringBuffer buf=new StringBuffer (" ");

For (int I=alstr. Length - 1; I>=0; I -) {
Buf. Append (alstr [I]), append (" ");
}
System. The out. Println (buf. ToString (). The substring (0, buf. Length () - 1));
  • Related