Urgent Codevita Question Doubt

this link has question and answer: QA
my doubt is if a company has sold a stock and some quantity is left over, can the company sell the remaining stock or not ?
what about test cases when there are multiple sells and buy for same company, we should output the company name multiple times or 1 time only ? pls help

u should output the company name with last transaction

1 Like

only the company with last transaction?
can v ouput same company name two time?
eg. someone sold an then he is still having some quanity left, so he should calcu;ate new price of remining items ?

if we have some amount left then we sell them if there is a chance so we should output that final price only