enter image description here
I check each cutting position and find the largest result. But this is really not optimal
I’m thinking another way is two pointers but I’m not really sure what to do yet
Does anyone have an optimal idea for this problem? Thank you very much
New contributor
farray46 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.