GoConqr hat ein neues Design! Sag uns, wie es dir gefällt.

Karteikarten

JS-Section2

dadou siplancin JS-EASY vaze Englisch 24 Karten

Karten in diesem Stapel (24)

  1. 1Number of data types in JS.Number
    String
    Boolean
    Null : Explicitly sets a variable with no value
    Undefined : For variables that have not yet been defined
    Object : Complex data structures
    Symbol : Used with objects.
    JS is loosely typed language
  2. 2Getting a character of a string fullNameconsole.log(fullName[0]);
  3. 3Getting the length of the string fullNameconsole.log(fullName.length);
  4. 4Pour mettre en Majuscule ou en minuscule :fullName.toUpperCase();
    fullName.toLowerCase();
  5. 5find the position of a character inside a string :fullName.indexOf('a')
  6. 6Avoir la dernière apparition d’une lettre d’un stringfullName.lastIndexOf(‘n);
  7. 7Couper la partie d’un string :fullName.slice(0, 10)
    The first argument is where we want the slice from. The next is when we where we want it to stop.
    Ou
    let result = email.substr (0,10) /* starts at 0, and gets 10 characters */
  8. 8Remplacer un caractère par un autre dans un stringlet result = email.replace('m', 'w');
    Le premier m rencontré sera remplacé par w.
  9. 93 puissance 5let result = 3**5
  10. 10order of operations :BIDMAS
  11. 11add ten to resultresult = result + 10;
    result += 10;
  12. 12const title = 'Best reads of 2019'; const author = 'Mario'; const likes = 30; Make template strings with those and the phrase "The blog called (title) by (author has (likes) likes"let result = `The blog called ${title} by ${author} has ${likes} likes`;
  13. 13const title = 'Best reads of 2019'; const author = 'Mario'; const likes = 30; Creating html templateslet html = `
    ${title}
    By ${author}
    This blog has ${likes} likes
    `;
  14. 14Array with 3 elements : let ninjas = ['shaun', 'ryu', 'chun-li']; Quelle commande donnera Ryu.console.log(ninjas[1]);
  15. 15Array with 3 elements : let ninjas = ['shaun', 'ryu', 'chun-li']; Quelle commande remplace Ryu par ken ?ninjas[1] = 'ken';
  16. 16Afficher la longueur de l'arrayconsole.log(ninjas.length);
  17. 17Quelle commande permet d'afficher chaque élément du tableau séparé par une virgule.console.log(ninjas.join(','));
  18. 18Savoir quelle est la position de chun-li dans l'arraylet result = ninjas.indexOf('chun-li');
  19. 19Quelle commande permet de concatenner ken et crystal avec l’array ninja.let result = ninjas.concat(['ken', 'crystal']);
  20. 20Quelle commande permet de concatainer l’array ages et l’array ninjas.let result = ninjas.concat(ages);
  21. 21What method can add Ken at the end of the array ?let result = ninjas.push('ken');
  22. 22How to take off the last value of the arraylet result = ninjas.pop();
  23. 23How to display the last value of the array ?console.log(ninjas.pop());
  24. 24—

Informationen

Beschreibung
vaze JS-EASY Karteikarten am JS-Section2, erstellt von dadou siplancin am 25/11/2021.
Erstellt von
dadou siplancin
Aufrufe
0
Bewertung

Feedback

Worum geht es?

Wie gefällt dir das neue Design?

Dein Eindruck