Recommend Movies by Genre
Medium📝 Description
Given a dictionary of movies by genre, return movies of a selected genre.
Input Format
{"Action": ["Movie1", "Movie2"], "Comedy": ["Movie3"]}, genre="Action"
Output Format
["Movie1", "Movie2"]
Constraints
Number of movies ≤ 1000
🔍 Sample Input
{"Action": ["Movie1", "Movie2"], "Comedy": ["Movie3"]}, "Action"
✅ Sample Output
["Movie1", "Movie2"]
Code Editor
Please login to run and submit code.
Results
Suggested Solution
Shortcuts: Ctrl+Enter to submit, Ctrl+Shift+R to run