Given three integers a ,b ,c, return the largest number obtained after inserting the following operators and brackets: +, *, () In other words , tr...
For further actions, you may consider blocking this person and/or reporting abuse
If one of the numbers is 1, and if the next bigger number is y and largest number is z, ans will be z * (1 + y), else ans will be x * y * z
So
Here is a Python solution,
Output,
Here is the simple solution for PHP:
maybe not the most elegant, but it work!
My solution using Rust .
Playground
In javascript
Hmm yes, but looking at the examplea given, I assumed a, b and c would be positive