Back to problems

Music Player

Object-Oriented Programming · Rippling · Medium

You must build the analytics engine for a cloud‑based music streaming platform. The system tracks when songs are added to the catalog and records every playback by a user. It can later produce a summary showing how many distinct users have listened to each song. All data stays in memory. Every song identifier and user identifier passed to the methods is guaranteed to be valid. Implement the MusicPlayer class: MusicPlayer() — initializes an empty player. int addSong(String…

Checking your access…