What function can be used to sort a Vector?

后端 未结 7 2140
故里飘歌
故里飘歌 2020-12-06 09:40

I cant find any sorting function in the java API for vectors. Collections.sort is only for List and not for Vector.<

7条回答
  •  日久生厌
    2020-12-06 10:08

    Collections.sort(nameOfTheVectorToBeSorted); try this on your vector, that will get sorted.

提交回复
热议问题