[25/11/14] fixed a bug where the list was created wrong, fixed the splitting
[25/11/14] reordered Code. finish first version of this script.