Probably easier just to insert each element in order as you're building the list. Then if you find it's slow for the inputs you want to handle, try doing the same thing with a binary tree instead....