← Visa questions
CodingMedium

Maximize stock profit within budget (0/1 Knapsack)

Filed under Visa

An investor has a fixed amount of savings and can purchase at most 1 share per company. Given the current price and predicted future price for each stock, determine the maximum profit achievable such…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Visa questions

Collected from public candidate posts and coding forums. Updated Nov 2026.