Contenido del Curso
Python Functions Tutorial
Python Functions Tutorial
Challenge: Search Engine
Swipe to show code editor
You need to implement a recursive function that searches for a file in a dictionary by its name. The dictionary contains file information, where each file has a unique id
, name
, and path
. The function should return the details of the file when it finds a match for the specified file name.
- Complete the code by filling in the missing parts (
___
) in the given function. - If the dictionary is empty, the function should return
None
. - If a file with the target name is found, the function should return the details of that file.
- The function should recursively check the remaining files after each file is checked, until the target file is found or all files are checked.
¡Gracias por tus comentarios!
Challenge: Search Engine
Swipe to show code editor
You need to implement a recursive function that searches for a file in a dictionary by its name. The dictionary contains file information, where each file has a unique id
, name
, and path
. The function should return the details of the file when it finds a match for the specified file name.
- Complete the code by filling in the missing parts (
___
) in the given function. - If the dictionary is empty, the function should return
None
. - If a file with the target name is found, the function should return the details of that file.
- The function should recursively check the remaining files after each file is checked, until the target file is found or all files are checked.
¡Gracias por tus comentarios!
Challenge: Search Engine
Swipe to show code editor
You need to implement a recursive function that searches for a file in a dictionary by its name. The dictionary contains file information, where each file has a unique id
, name
, and path
. The function should return the details of the file when it finds a match for the specified file name.
- Complete the code by filling in the missing parts (
___
) in the given function. - If the dictionary is empty, the function should return
None
. - If a file with the target name is found, the function should return the details of that file.
- The function should recursively check the remaining files after each file is checked, until the target file is found or all files are checked.
¡Gracias por tus comentarios!
Swipe to show code editor
You need to implement a recursive function that searches for a file in a dictionary by its name. The dictionary contains file information, where each file has a unique id
, name
, and path
. The function should return the details of the file when it finds a match for the specified file name.
- Complete the code by filling in the missing parts (
___
) in the given function. - If the dictionary is empty, the function should return
None
. - If a file with the target name is found, the function should return the details of that file.
- The function should recursively check the remaining files after each file is checked, until the target file is found or all files are checked.