Disney+ Hotstar Interview Question

Implement pluck method like underscore library