arasmr / javascript-2 Goto Github PK
View Code? Open in Web Editor NEWHYF JavaScript module2
HYF JavaScript module2
Your code is neat and clean, and properly indented. I have no comments actually, well done!
Hi Emre, here is my feedback on your homework.
Your homework was late.
OK
OK, but you do not need to reconfirm that 15 is divisible by both 3 and 5. The preceding console.log statements already tell that.
OK
OK
freeCodeCamp uses var
but remember that if you have a choice you should use let
and const
instead.
Missing
See the solution I posted in slack how you can do this with a recursive function.
The function that you return from createBase
should not do a console.log but simply return the result of the addition. It's already implied by the name of, say, addSix
. We expect this function to add 6 to the supplied parameter and return the result. If we wanted the function to console.log the addition we would have chosen a name like addSixAndPrint
or something like that.
Good to see that you can google, but I would have preferred to see a solution that you created yourself.
Dear Emre,
Your code looks good, seems you worked hard. Here are my comments:
1- Your line13 could have been easier without using if like this: let filteredNumbers = numbers.filter(x => x % 2 !== 0);
And you did not console.log it too.
2-Line 19 could also be simplified as: let mapNumbers = filteredNumbers.map(x => x * 2);
you do not have to use return or parenthesis with x.
3.Your code seems to work with tasks. Good job, although Jim was saying not to use .push?!
4-There is no comment in your code, forexample I wanted to know what does Math.trunc does, or what other parts do, or at least you could paste the question and comment it.
5- Optimize and change your code and upload a revised version whenever you
Good luck further!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.