Java: Get last element after split

后端 未结 12 1827
慢半拍i
慢半拍i 2020-12-02 11:31

I am using the String split method and I want to have the last element. The size of the Array can change.

Example:

String one = \"Dü         


        
12条回答
  •  感情败类
    2020-12-02 12:30

    You mean you don't know the sizes of the arrays at compile-time? At run-time they could be found by the value of lastone.length and lastwo.length .

提交回复
热议问题