java - How to rewrite ArrayList in opposite direction -


this question has answer here:

i have arraylist , need rewrite in opposite direction. how it?

list<posts> viewlist = new arraylist<posts>();  viewlist = viewlogic.getpostslist(username); 

you can use:

collections.reverse(viewlist); 

as documented oracle here.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -