User Profile
Collapse
-
I want to take every Flip value from second list and subtract that with all the Flip values of first list and insert the corresponding key value pair into first list where the difference between the values is lesser this is to maintain the order of first list values(as they are already sorted) -
Create a new list from 2 lists of ordereddict after custom sort
I have 2 lists of ordereddict which i fetch from DB through a function and they look like below
Code:**First list printed output:** OrderedDict([('Items', '1'), ('Itemspaid', 'Rutr'), ('First', 'Het'), ('Second', 'Fru'), ('Third', 'yurn'), ('Flip', 223.513353868968)]) OrderedDict([('Items', '2'), ('Itemspaid', 'Rutr'), ('First', 'Het'), ('Second', 'Fru'), ('Third', 'yurn'), ('Flip', 243.513353868968)])
No activity results to display
Show More
Leave a comment: