Tutup

Python data structure

Proyek ini menerima 26 penawaran dari para freelancer berbakat dengan harga penawaran rata-rata $25 USD.

Dapatkan penawaran gratis untuk proyek seperti ini
Pemberi kerja bekerja
Anggaran Proyek
$10 - $30 USD
Total Penawaran
26
Deskripsi Proyek

Given a dictionary of dictionaries of format {key: {key: value, ...}, ...}, for example:

{'word1': {'word2': 0.5, 'word3': 0.5}, 'word4': {'word5': 0.5, 'word6': [url removed, login to view], 'word7':[url removed, login to view]}, 'word3': {'word8': [url removed, login to view], 'word9': [url removed, login to view], 'word10': [url removed, login to view]}, 'word5': {'word11': 0.5, 'word12': [url removed, login to view], 'word13': [url removed, login to view]}, 'word14': {'word15': 1}, 'word11': {'word15': 1}}

create a function that takes the dictionary, a word and a level as parameters and builds a graph (tree) for that word as a root with associated dictionary words as children and their values as edges. The function should return a dictionary of words for the product of all edges values that create a path from root to each node at the given level.

Example: given the dictionary above, 'word4', and distance 2 the function should return {'word11': [url removed, login to view], 'word12': [url removed, login to view], 'word13': [url removed, login to view]}

If you have any questions, do not hesitate to ask!

Keahlian yang Diperlukan

Ingin menghasilkan uang?

  • Atur anggaran Anda dan jangka waktunya
  • Uraikan proposal Anda
  • Dapatkan bayaran atas pekerjaan Anda

Pekerjakan para freelancer yang juga menawar di proyek ini

    • Forbes
    • The New York Times
    • Time
    • Wall Street Journal
    • Times Online