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.
I made this Kata for beginners. It may be trival for you, but it will help beginners.
thank you.
I used vector this time thank you
if there was multiple closest values return first closest value.
//no need to use a loop
a.erase(0,1);
a.erase(a.size()-1,1);
return a;
The auto keyword in C++ automatically detects and assigns a data type to the variable with which it is used. The compiler analyses the variable's data type by looking at its initialization.
so in my case maybe the compiler takes longer time to compile the code but if I write std::string or auto they will do the same job
Thank you so much
Can someone explain to me what happens in the last line? return *p = 0, string;