Find Your Bootcamp Match
- Career Karma matches you with top tech bootcamps
- Access exclusive scholarships and prep courses
1. JS Basic
Solution: The solution is to input your variable as the current day and assign the new date to it.
2. JS Variables
Solution: The solution is to create a value to a variable “var” and assign a value to it. Next, you will learn to display values using variables. In this particular example, you will create a variable car name with the term “Volvo.”
3. JS Operators
Solution: This exercise will require you to multiply data values 10 and 5 and alert the answer. Next is to divide two values 10 and 2 and alert the result. Afterward, you have to get the remainder of another set of values, when 15 is divided by 9. Lastly, choose the assignment operator that will result in two values being added up.
4. JS Functions
Solution: Your solution is to learn to create, name, and execute a function using ‘myFunction’ to alert “Hello World!” Then, you will make the function return the “Hello” and lastly, make the function display “Hello.”
5. JS Events
JS events happen when a user or browser manipulates a page and the page loads. Every other thing that occurs when the user is on that page is also an event. For instance, when the user clicks a button, closes a window, or presses any key. This exercise teaches you how to create a button that triggers a response when someone clicks on it.
Solution: Create a button element that does something when someone tries to click on it, for example, “onclick.” Then, create a function that should be executed when the button is clicked and name it. Lastly, create a color that appears when the user clicks on the button.
6. JS Strings
Solution: Create a string to array function, use the length property to alert the length of the function, use escape characters to write the string, then split the string to get the output. For example, [‘Hello, World’] or [“Hello, World”].
7. JS Comparisons
Solution: Choose the correct comparison operator to alert true when x is greater than y. That is, “x=10; y=5; alert(x>y).” Another is to choose the comparison operator to alert when x is not greater than “y x=5; y=10; alert(x!>y).”
8. JS Arrays
Solution: First, you have to create your variable, input the function, and then set the program to return a boolean value. Afterward, you have to alert the number of items in an array using the correct array property.
9. JS Conditions
Solution: What you have to do here is to include “if” at the beginning of the variables x and y to alert the function and “else” at the beginning of the alert.
10. JS Math
Solution: The solution is to let x = math.sqrt(9).
"Career Karma entered my life when I needed it most and quickly helped me match with a bootcamp. Two months after graduating, I found my dream job that aligned with my values and goals in life!"
Venus, Software Engineer at Rockbot
- Code Wars. Code Wars is an online coding platform that allows you to learn and practice coding. This platform has challenge libraries that allow programmers who are a part of this community to participate in coding challenges and build their knowledge and skills.
About us: Career Karma is a platform designed to help job seekers find, research, and connect with job training programs to advance their careers. Learn about the CK publication.