Today, i have notification from inspiration @codr [Road to be Genius Superior #51 (https://dev.to/codr/road-to-genius-superior-51-2c3f). Sometimes i used to Javascript for developing web client. My focus already change from software engineering to Data Scientist or Machine Learning. So, i am trying to port javascript to python, i am already creating this gist.Okey, this is the code of Javascript.
The next, it is my code of python. I have tried to understand line by line and porting to syntax python.
I think is not quite different with Javascript but, the result is different, maybe i have missed something in python code.
For better known the result check the blog of @codr , or any idea about this python coding, you can comment here.
Top comments (2)
I'm not at a machine so I can't test anything right now, but Pythons range() function stops BEFORE the ending number, is this an off-by-one mistake?
yup, that rights