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 do know how to answer a question without being a dick, don't you?
"...Write a function insert_dash(num) / insertDash(num) / InsertDash(int num) that will insert dashes ('-') between each two odd numbers in num. For example: if num is 454793 the output should be 4547-9-3. Don't count zero as an odd number..."
Why not 45-4793? Or 45-47-9-3? etc
Nice
Ta.
On the random tests, the very last test fails consistently so am looking for some help/pointers.
Consider this random test string:
"mntznaesr swairiyjmk rtdabu ujbdwexulp otvk trtuzgkuat nuhpcwyg lfeefwxab clwjbwr iikxtazs dxlchvwfr vxotlonry dmjwt"
according to the test then 'trtuzgkuat' (score=155) is the max word despite the fact that 'vxotlonry' (156) is the max word.
Similarly with the following word string:
"pkfever cqehicl dfkywqa rkipisr zssov rtbkzh xppehierj spdkzta usrkx txdmzsw kczatzvk umvmj yltrncbou oliradka qjdi ywxi uaxcrhyli"
the test states that 'yltrncbou' (121) is the max word when 'txdmzsw' (122) has the max value.
So, anyone else had this problem? Or got any tips/pointers as to the resolution.
Thanks!
Sorry? "print the input to the console" ?
Hi,
I can run the Sample tests fine and all four pass but when I try the "Attempt" tests then all but the last test passes, and gives me an error:
'))(()())())' should equal '()(((())())'
Is there a way to see what the actual test case is? This is only my 2nd day on Codewars so am still getting settled in.
I can then debug my code as needed.
Thanks!
Gary