TikTok interview question

Coding interview: To write a program to determine highest profitable stock.