Adrinlol/linkedin-javascript-assessment

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 

Repository files navigation

LinkedIn Assessments - JavaScript 2019-2021

  • ~15 minutes duration
  • 70th percentile required to pass and get a badge
  • Retry in 3 months if you don’t pass

button.addEventListener('click', function(e) {
  button.className = 'clicked';
}, false);
  • e.preventDefault();

 <p class="pull">Lorem Ipsum </p>
  • document.querySelector(".pull");

let rate = 100;

let modal = document.querySelector('#results');
setTimeout(function() {
  modal.classList.remove('hidden');
}, 10000);
console.log('Results shown');
  • Immediately

  • var student = new Person();

  • When you want your code to choose between multiple options.

  • A for statement is generic but a forEach statement can be used only with an array.

addTax(50);

var Storm = function () {};
Storm..precip = 'rain';
var WinterStorm = function () {};
WinterStorm. = new Storm();
WinterStorm..precip = 'snow';
var bob = new WinterStorm();

console.log(bob.precip);
  • 'snow'

  • It returns a reference to a variable in its parent scope.

"use strict";
function logThis() {
  this.desc="logger";
  console.log(this);
}

new logThis();
  • logThis { desc: 'logger' }

console.log(typeof(42));
  • 'Number'

  • !==

let rate = 100;

var student = new Person();

roadTypes[2]

  • target

JSON.parse()

  • When you want your code to choose between multiple options

for(var i=0; i<5; i++){ 
  console.log(i); 
}
  • 01234

  • Generator

for (var i=1; i<=4; i++){
   setTimeout(function(){
       console.log(i);
   }, i*10000);
  }
  • for (var i = 1; i <= 4; i++) {{function(j) {setTimeout(function() {console.log(j);}, j * 1000);})(i)};

  • let discountPrice = function(price) { return price * 0.85; };

  • /\d\d:\d\d:\d\d/

let arr = [];
  • 2

  • instanceof

var start = 1;
if (start === 1) {
  let end = 2;
}
  • block

const x = 6 % 2;
const y = x ? 'One': 'Two';
  • Two

  • throw

  • The defer attribute will asynchronously load the scripts in order

var a;
var b = (a = 3) ? true: false
  • The condition in the ternary is using the assignment operator.

<p class="pull">lorem ipsum</p>
  • document.querySelector('.pull');

let answer = true;
if (answer === false) {
  return 0;
} else {
  return 10;
}
  • 10

var start = 1;
function setEnd() {
  var end = 10;
}
setEnd();
console.log(end);
  • ReferenceError

function sayHello() {
  console.log("hello");
}

console.log(sayHello.);
  • undefined

  • Set

var a;
var b = (a = 3) ? true: false
  • The condition in the ternary is using the assignment operator.

class X{
    get Y(){return 42;}
}
var x = new X();
  • x.Y

sum(10,20);
diff(10,20);

function sum(x,y){
  return x+y;
}

let diff = function(x,y){
  return x-y;
}
  • ReferenceError

  • Arguments

[] == [];
  • False

  • Side effects are not allowed.

  • instanceof

const x = 6 % 2;
const y = x ? 'One' : 'Two';
  • Two

let answer = true;
if (answer === false) {
  return 0;
} else {
  return 10;
}
  • 10

function printA() {
  console.log(answer);
  var answer = 1;
}
printA();
printA();
  • undefined then undefined

  • to start tasks that might take some time without blocking subsequent tasks from executing immediately

About

LinkedIn JavaScript Assessment Answers - 2019-2021

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

    Packages

    No packages published

    Contributors 2

    •  
    •