¡GoConqr estrena diseño! Cuéntanos qué te parece.

Fichas

Variables and Operators

Lucas Bastos Javascript Técnico Portugués 13 fichas

Fichas del conjunto (13)

  1. 1Name the three ways to declare a variablevar
    let
    const
  2. 2Which of the three variable declarations should you avoid and why?var - due to its function scope, which can lead to confusion.
  3. 3What rules should you follow when naming variables?Use descriptive names in camelCase, avoid reserved words and spaces, maintain consistency, and steer clear of confusing abbreviations.
  4. 4What happens when you add numbers and strings together?They are concatenated, rather than added
  5. 5How does the Modulo (%), or Remainder, operator work?Returns the remainder of the division operation
  6. 6Explain the difference between == and ===== Compares the values
    === Compares values ​​and type
  7. 7When would you receive a NaN result?When you try to do any operation with string other than addition
  8. 8How do you increment and decrement a number?Using ++ or -- before or after the variable where the number is stored
  9. 9Explain the difference between prefixing and postfixing increment/decrement operators.The prefix increments the variable first and then performs the operation. Postfixing executes the operator first and then increments the variable.
  10. 10What is operator precedence and how is it handled in JS?Operator precedence defines the order of evaluation for operators in an expression. Higher precedence operators are evaluated first. For example, in 2 + 3 * 4, multiplication occurs before addition. Parentheses can change this order.
  11. 11How do you access developer tools and the console?In the browser, right clicking -> inspect -> console or using the shortcut Ctrl + Shift + I
  12. 12How do you log information to the console?Using the console.log method
  13. 13What does unary plus operator do to string representations of integers? eg. +”10”Convert string to number

Información

Descripción
Técnico Javascript Fichas sobre Variables and Operators, creado por Lucas Bastos el 10/10/2024.
Creado por
Lucas Bastos
Visitas
1
Valoración

Escríbenos

¿Sobre qué es tu mensaje?

¿Qué te parece el nuevo diseño?

¿Te gusta?