+ 1
A question in solutions. (No Numerals)[solved]
In solutions, No Numerals question. When I check it myself there doesn't seem to be a problem. But when i try it in solutions It doesn't work and test number 3 fails every time i check it. If anyone could find a case that the output is wrong, or find a problem in the code i would appreciate it. , Thanks in advance. ✨✨✨✨✨✨✨✨✨✨ ##################### The problem is solved. ##################### ✨✨✨✨✨✨✨✨✨✨ https://code.sololearn.com/cjKVouJjWyN9/?ref=app https://code.sololearn.com/cjKVouJjWyN9/?ref=app
7 Réponses
+ 3
I tried input of "67 hh 9 hh" and i see same output, without 9 being changed to nine
Btw, here is a catalog of Danijel's tutorials, you can find Java RegEx tutorials / examples by filtering :
https://code.sololearn.com/WKFF4vOCr3mi/?ref=app
+ 3
The number can have more than two digits.
+ 3
numbers larger than 10 remains unchanged.
You only need to convert 0 to 10 to words.
Instead of using split(), you should
Use Regular Expression to extract all the numbers as an array, and then
Loop over the array,
Checking whether the number is less than 11, and if so,
Use switch statement on 0 to 10,
and swap the element in the array.
At last, replace the numbers in string with the result array
+ 1
Gordon
It's working now.
Thanks it was the case that there was one number between spaces that kept program fail.
Thank you for good explanation and finding the exception in my code.
0
Sorry but from what i undersood from the question it must print every number and for numbers equal to or less than 10 must print one,two,...
Am i wrong?
So i should just write one or two digit numbers?
0
When i check it numbers larger than 10 remain unchanged.
But if you found an exception please tell me about it.
What number more than 10 changes?
Yeah that i know.
I shouldn't have splited it but now there are a lot of code to change if i want not to split it.
Gordon
Thanks for the explanation definitely helpful.
but still i didn't get whether you think my code changes numbers more than ten or not.
because when i check it it only changes number less than 10
0
Hello
I need a little help with js checking a color/ overlap.
My first idea is to check the color around a player but I can't find a good tutorial.
My secound idea was to crate a square and with a for loop the properries, variables (xpos1, xpos1,... Backgroundcolor) but here is the problem that I can't find anything how to change the number in a variable.
The other thing is the second for loop which checks the overlap with every element after pushing an arrow key.
Please teach me how to code the color dedection around a square which triggers a event.