#!/usr/bin/env python
# coding: utf-8

import operator

A = [239, 1678, 2678, 4430, 199]
B = [4126.77552299, 984.39685939, 237.92397237, 497.72447701, 3377.17916825]

sorted_B = sorted(B)
locations = sorted(range(len(A)), key=A.__getitem__)

result = [None]*len(B)
for i, elem in zip(locations, sorted_B):
    result[i] = elem
    
print result