LeetCode Question · Mar 2020 · Los Angeles

Google | Phone | Product of last K elements - Foobar

10 upvotes 2,758 views 6 replies

Question Details

Class Product will have 3 methods: 1. constructor with k 2. Insert() with int parameter 3. Get () -> Returns the Product of the last k Insert() Example: Product(3) Insert(4) Insert(7) Insert(2) Get() -> 274 = 56 Insert(1) Get() -> 1...

Full Details

🔒

Unlock full leaked content

Full insider details, leaked discussions, and candidate experiences.

Get Premium →

Topics

General Experience