Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
You can try using print functions to see whats being passed in as input.
lgtm
Was wondering why I couldn't merge this but I guess I already had.
Merged
I removed the function names and just used the input -> output format for the main function (max() is still a function like in your example)
The description is just in psuedocode, none of the languages supplied invoke the function exactly like how its described in the description. What should it be changed to?
Ok, merging
Lgtm
Is it possible to add a random test?
I apologize for the C++ code, I asked my friend to write a C++ solution because I wrote the Java one. I refactored his C++ code to make it like the Java edition and it now it is identical to the Java one in terms of control flow. I also added random tests up to array size 50, and also kept size 1000 array random tests for both C++ and Java.
I added an srand call before the random tests begin. As for the solution, can I see what you have? I don't believe the reference solution is wrong, but I may be mistaken.