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 have to return an array of strings, you're returning a string there.
I think I know what method you are using. If it is the one I am thinking of, then if there are no results then null is returned. You are calling length method on null, which leads to your error.
Perhaps you are trying to get length of an array in JS style which doesn't work in PHP. It should be
count($arr)
. Or, if you trying to get length of string it also should be done in other way which isstrlen($string)
Well Nice
Yavor
.. But For More inner Secure Take A look at the Concept of the Kata ItSelf (i.e) ** The algorithm used in Solving the Problem ** .. Is it Similar To any Other katas ?? if so .. how about giving Yours A Little Twist To chanllange The Trainee ?? .. and Go ahed, Bro .. You're Are On the right Path ....Wish you the Best
Yavor
... regrads ...Zizou
No ... the Kata Still in ** Beta Phase ** .. There are some Kata on the site Still in ** Beta Phase ** From September 2013 ... Yeah don't panic ... whether it was not an Original Idea or .. one of the Previous Points ...
BUT when The Kata is Approved , You've got a message Notify you that
Kata Has Been Approved
Like This :Approved Kata Message
Wish you all the Best
Yavor
Yeah .. It's a good Question
Yavor
.. Determining whether The Kata's idea is Original or duplicate Really economise all the Efforts dedicated to Publish it ..and ther is a
Simple Way to Do it
..1- when you enter The ** codeWars** Page , there is a RED Symbol on the Upper Left , From the sub-Menu choose **Kata and **click on it .
2- On this Page you'll find on the Left a ** Search cell** Where you can Put The Lables that you want To Search for , for Example (DataTypes , Loops , fundamentals ...) also It could be Used to Type in The Keywords to Search for .
Let''s Assume
you've Master
Loops
and Want to Trian yourself and sharpen your Skills in this topic , simply Put the KeyWord ** Loops** in the Search Cell .Same applied if you've an Idea concerning Publishing a kata , a good routine is To scan ** Previous Katas Published ** so no duplicate Occurs ...
** hope you the Best **
Yavor
... and Please ... Mention Me as Soon as your Very First Kata Approved to Catch the honor of translating it to **Mine Languages ** ... regards ...Zizou
Well
Yavor
... When you Post a Kata Still in **( Beta Process) ** Where Contibutions Occurs .Kata Published have to Satisfy Some Criterias ::
(The Code Should run Effectively) , Test Cases and Example Test Cases (Which Appear Only to The Trainee) Must Validate THe Solution , If Not ( Issues are Raised) .
The Random test Cases Should be Included Also .
and ** Of Course ** The kata's Idea Should be Original (No Duplicates Allowed) .
and finally The Satisfaction Rate (Measuring How content are the Trainee about the Kata's Overall).
Also The Descripiton should Be Clear , Determining the Task Should be done By The Trainee With no Ambiguity .
That's Some of (and Personally) , I've Published 22 Kata's Only ** half ** of them are Approved .
So
Yavor
if There is an advice , then..Try to Solve more Katas
In your Languages
, Then Take a look at the *Overall Format of the Testcases and Description *Try *Scanning *The Approved Katas
In your Languages
and Figure Out what in common Factors that Make them approved (Besides The Previous Points) .Hope You the Best
Yavor
.. and I Promise your Very First Kata Will be * Approved * , I'll Translate it to theC++
So As many Trianees Can Solve it , wish You All the BestYavor
.. Regards ..Zizou
No problem, it seems that when BF translation was added it changed the instructions for all languages and that can be confusing, I've added a suggestion so the author can fix it.
In js no string ends with
"\0"
that is only for BF (another language). Remove that from your code.Show your code, mark your post as having spoiler content. The tests are ok.