If there any thing you could tell me I well be thankful
So first of all, you want to sort the items and want untitled items to be first?
If yes, first you need to fix your sorting algoritm. Just forget about untitled, you can remove that part for now.
I guess you tried to implement a bubble sort?
https://www.geeksforgeeks.org/bubble-sort/
You can compare the code with the implementation or try to execute your loops in your head step-by-step to figure out what is broken in your sorting algoritm. But I would suggest to use a debugger for that (just google "how to use debugger in [name of your IDE]"), it allows to execute your app step-by-step and investigate the state.
Once you make your sorting work, test it on different inputs. Once you checked that it works on different inputs, instead of "vect[j - 1] > vect[j]" you need to add a similar check with what we discussed the last time above with "untitled". If you have a proper sorting algoritm you need to modify only the condition to achieve the correct behavior.