An Interest In:
Web News this Week
- April 2, 2024
- April 1, 2024
- March 31, 2024
- March 30, 2024
- March 29, 2024
- March 28, 2024
- March 27, 2024
December 31, 2021 10:12 pm GMT
Original Link: https://dev.to/jennifer_tieu/self-taught-developer-journal-day-29-top-javascript-fundamentals-part-2-practice-and-knowledge-check-10e0
Self-Taught Developer Journal, Day 29: TOP JavaScript Fundamentals Part 2 - Practice and Knowledge Check
Today I completed The Odin Project JS Fundamentals Part 2 Knowledge Check Section after reviewing all of the materials.
Knowledge Check
- What are the eight data types in JavaScript?Numbers, BigInt, Strings, null, undefined, Boolean, Objects, Symbols
- Which data type is NOT primitive?Objects
- What is the relationship between null and undefined?The expression,
null == undefined
, returns true when using the loose equality operator, "==", but not for, "===" - What is the difference between single, double, and backtick quotes for strings?Single and double both behave the same. Backtick quotes can format strings with variables and expressions.
- What is the term for embedding variables/expressions in a string?Template literals
- Which type of quote lets you embed variables/expressions in a string?Backticks
- How do you embed variables/expressions in a string?${...}
- How do you escape characters in a string?Put a blackslash, "\", in front of a character
- What are methods?Actions performed on Objects
- What is the difference between slice/substring/substr?Slice extracts a part of a string and returns the extracted part in a new string.Substring is similar to slice, but can't use negatives indicesSubstr is similar to slice, but the second parameter specifies the length of the extracted part.
- What are the three logical operators and what do they stand for?&& (AND), || (OR), ! (NOT)
- What are the comparison operators?Operators that compare values between operands
- What are truthy and falsy values?Values that return the boolean value true or false
- What are the falsy values in JavaScript?0, empty string, null, NaN, and undefined
- What are conditionals?evaluates whether a statement/expression is true or false
- What is the syntax for an if/else conditional?Refer to end
- What is the syntax for a switch statement?Refer to end
- What is the syntax for a ternary operator?
condition ? value1: value2;
- What is nesting?Putting a statement inside of another statement, therefore nesting them.
For Question 16:
if { ...} else { ...}
For Question 17:
switch (condition) {
case a:
code block
break
default:
code block
}
Resources
Original Link: https://dev.to/jennifer_tieu/self-taught-developer-journal-day-29-top-javascript-fundamentals-part-2-practice-and-knowledge-check-10e0
Share this article:
Tweet
View Full Article
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To