Preguntas de entrevistas para Front end developer

8 K

Preguntas de entrevista para Front End Developer compartidas por los candidatos

Preguntas de entrevista principales

Ordenar: Relevancia|Popular|Fecha
Accenture
Se le preguntó a Senior Front End Developer…14 de julio de 2017

What are your greatest technical strengths?

8 respuestas

Management

Social media experience

I am technically sound in using R script for R programming language, base SAS, SAS analytics and Advanced SAS. Menos

Mostrar más respuestas
LinkedIn

// Given var endorsements = [ { skill: 'css', user: 'Bill' }, { skill: 'javascript', user: 'Chad' }, { skill: 'javascript', user: 'Bill' }, { skill: 'css', user: 'Sue' }, { skill: 'javascript', user: 'Sue' }, { skill: 'html', user: 'Sue' } ]; getSkills = (endorsements) => { // Result // [ // { skill: 'javascript', user: ['Chad', 'Bill', 'Sue'], count: 3 }, // { skill: 'css', user: ['Sue', 'Bill'], count: 2 }, // { skill: 'html', user: ['Sue'], count: 1 } // ]; } see this image: http://i.imgur.com/UIeB3n4.png

7 respuestas

let endorsements = [ { skill: 'css', user: 'Bill' }, { skill: 'javascript', user: 'Chad' }, { skill: 'javascript', user: 'Bill' }, { skill: 'css', user: 'Sue' }, { skill: 'javascript', user: 'Sue' }, { skill: 'html', user: 'Sue' }, ]; let x = endorsements.reduce((acc, { skill, user }) => { if (skill in acc) { acc[skill] = { user: [...acc[skill]['user'], user], count: acc[skill]['count'] + 1, skill: skill, }; } else { acc[skill] = { user: [user], count: 1, skill: skill, }; } return acc; }, {}); console.log(Object.values(x)); Menos

I did in a different way let outPut = []; let skillMap = {}; for (let char of endorsements) { if (char['skill'] in skillMap) { skillMap[char['skill']] = [...skillMap[char['skill']], char['user']]; } else { skillMap[char['skill']] = [char['user']]; } } for (let key in skillMap) { let skillObj = {}; skillObj['skill'] = key; skillObj['user'] = skillMap[key]; skillObj['count'] = skillMap[key].length; outPut.push(skillObj); } return outPut.sort((a, b) => b.count - a.count); Menos

getSkills = endorsements => { const skillMap = {}; // assumption - each object has all the properties, nothing is missing endorsements.forEach((item, index) => { const { skill, user } = item; if (!skillMap[skill]) { skillMap[skill] = {}; skillMap[skill]["user"] = []; // skillMap[skill]["user"].push(user); skillMap[skill]["count"] = 0; } skillMap[skill]["user"].push(user); skillMap[skill]["count"] += 1; // } }); return Object.keys(skillMap).map(key => [ { skill: key, ...skillMap[key] } ]); }; Menos

Mostrar más respuestas
Booking.com

In your opinion, what is our company's single most important metric?

7 respuestas

Reservations per day I guess

It's always revenue my man/woman

"It's always revenue my man/woman." I hope you understand how irrelevant you observation is in the context of this position. So no, it's not "always revenue." Menos

Mostrar más respuestas
PE International

"If you were stranded on a desert island, what three development tools would you bring with you?"

5 respuestas

This ridiculous, senseless question was the first one asked. It set the tone for what was to follow. Menos

IDE, Build Tools, Version Control!

Git, Codio, and Netflix

Mostrar más respuestas
Bloomberg L.P.

What is a JavaScript callback function?

5 respuestas

A callback function is a piece of JavaScript code that executes after the main function that the callback is attached to executes successfully. Menos

udaykanth, I would say that a .forEach() would be the most common and most basic use of a callback function. I'm just writing this to help anyone that might have a hard time thinking up a quick example if the come across this question themselves. Example: var numArray = [ 1, 2, 3 ] ; numArray.forEach( function( i ) { console.log( arr[ i - 1 ] ) } ) ; // logs out // 1 // 2 // 3 Menos

Is there a front end role at bloomberg. I guess your position must have been labelled software dev right? altho ur a dront end dev Menos

Mostrar más respuestas
Meta

Given an array where each entry can be another array, and so forth, flatten the array. [4, [3, 6, [9, 1, 9, [5, 1]]], 8] -> [4, 3, 6, 9, 1, 9, 5, 1, 8]

5 respuestas

Assuming that we are solving this in Java, I am treating an array as an array list // Use Hash Set to prevent infinite loops HashSet hs = new HashSet(); ArrayList flatten_list(ArrayList arr, HashSet hs) { ArrayList result = new ArrayList; int len = arr.size(); if(len < 1) return result; // Empty List. for(int i = 0 ; i Menos

function serialize(a, start){ if(start >= a.length) return a; if(Array.isArray(a[start])) return serialize([...a.slice(0,start),...a[start], ...a.slice(start+1,a.length)], start+1); return serialize(a, start+1); } Menos

const flatten = array = > { return array.reduce((elem, acc) = > { return elem.concat(Array.isArray(acc) ? flatten(acc) : acc) }, []) } Menos

Mostrar más respuestas
IBM

1. To add an HTTP request to the search engine, then log a result depending on the# of pages and requirements. 2. Use DP to implement a Knapsack-like problem. Restrictions on time complexity. 3. Implement a to-do list's delete method on website.

5 respuestas

To X: Get rejected

Did they request to do a background screening on you before rejecting?

No

Mostrar más respuestas
LinkedIn

// How can I know which radio was clicked or selected? <h2>Monstrous Government Form</h2> <form id="myForm" name="myForm"> <fieldset> <legend>Do you live in an:</legend> <p><input type="radio" name="home" value="apartment" id="apartment" /> <label for="apartment">Apartment</label></p> <p><input type="radio" name="home" value="house" id="house" /> <label for="house">House</label></p> <p><input type="radio" name="home" value="mobile" id="mobile" /> <label for="mobile">Mobile Home/Trailer</label></p> <p><input type="radio" name="home" value="coop" id="coop" /> <label for="coop">Co-op</label></p> <p><input type="radio" name="home" value="none" id="none" /> <label for="none">None</label></p> </fieldset> <fieldset> <legend>Your income is:</legend> <p><input type="radio" name="inc" value="0-50K" id="0-50K" /> <label for="0-50K">$0-50,000 USD</label></p> <p><input type="radio" name="inc" value="50-100K" id="50-100K" /> <label for="50-100K">$50,000-100,000 USD</label></p> <p><input type="radio" name="inc" value="100K+" id="100K+" /> <label for="100K+">$100,000+ USD</label></p> </fieldset> <fieldset> <legend>Your status is:</legend> <p><input type="radio" name="status" value="single" id="single" /> <label for="single">single</label></p> <p><input type="radio" name="status" value="married" id="married" /> <label for="married">married</label></p> <p><input type="radio" name="status" value="partner" id="partner" /> <label for="partner">domestic partner</label></p> </fieldset> <p>This form goes on with another 97 questions....</p> <input type="submit" value="Submit" /> </form>

5 respuestas

Attach the event listener to the form id="myForm"...

document.querySelector('input[name="house"]:checked').value;

you can add oncl1ck event to assign event target value to a variable for each fieldset, since there are 3 different field sets, and we want to know each of them separately. Menos

Mostrar más respuestas
Yahoo

Design a data structure to store sparse 2D matrix which contains only 0 or 1. then write function to add 2 such matrix.

4 respuestas

use run-length encoding.

store each row as a decimal for ex: if the row is 1011 -&gt; store it as 13!

Since all values are mod 2 you can pack 64 entries together into on int64_t. You can then add two matrices by XORing each entry. Menos

Mostrar más respuestas
Pinterest

How many characters in the front of a string would need to be added in order to make it a palindrome.

4 respuestas

Here's a python solution: def min_add_for_pal(word): drow = word[::-1] # Reverse string if drow == word: return 0 for shift in range(len(word)): if word[:-shift] == drow[shift:]: return shift return None # Shouldn't reach here Menos

A better asnwer is to do it in-place with pointers. O(N) speed and O(N) space. function checkPalindrome(i, input){ var leftPointer = 0; var rightPointer = 0; if(i===0){ //base case of single char return true; } var odd = (i+1)%2; //we know it's not 0 if(odd){ leftPointer = i/2; //not 0 rightPointer = i/2; //not 0 while(input[leftPointer] === input[rightPointer] &amp;&amp; leftPointer &gt; 0 &amp;&amp; rightPointer 0 &amp;&amp; rightPointer &lt; input.length){ leftPointer = leftPointer - 1; rightPointer = rightPointer + 1; } } if(input[leftPointer] === input[rightPointer] &amp;&amp; leftPointer === 0){ return true; }else{ return false; } } var improvedMinPalindromeAddition = function(input){ var inputArray = input.split(""); //max string size is greater then max array size(4.29 billion elements)..we could also do it inline w/string manipulation var largestPalindrome = 0; for(var i=0;i Menos

function isPallindrom(str) { if (!str) return; let start = 0; let end = str.length -1; while (start start) { console.info(str.substring(0, end)) if (isPallindrom(str.substring(0, end))) { return count; } else { count++; } end--; } return count; } Menos

Mostrar más respuestas
Viendo 1 - 10 de 8191 preguntas de entrevistas