Skip to content

Instantly share code, notes, and snippets.

@eshrinivasan
Last active May 28, 2018 08:47
Show Gist options
  • Save eshrinivasan/cb5dce322891c6c606c9cd5871296d0d to your computer and use it in GitHub Desktop.
Save eshrinivasan/cb5dce322891c6c606c9cd5871296d0d to your computer and use it in GitHub Desktop.
UI questions
<h2> Javascript</h2>
What are the differences between null and undefined?
What are the differences between == and ===?
What is reflow? What causes reflow? How could you reduce reflow?
What is repaint and when does this happen?
What does defer and async keyword does in a script tag?
What is the difference between .call and .apply, .bind?
Explain "this" in javascript
Explain prototypal inheritance in javascript
<h2> JQuery </h2>
What is the difference between jQuery find and children?
Is it possible to include multiple versions of jQuery on the same page? How
do you avoid conflicts that may occur between jQuery vs other javascript libraries?
Name some of the jQuery selectors?
<h2> Angular </h2>
List a few ways to improve performance in an AngularJS app.
What is data binding in AngularJS?
broadcast vs emit
Difference between service and factory in AngularJS
Explain what are directives ? Mention some of the most commonly used directives in AngularJS application ?
@eshrinivasan
Copy link
Author

JS Dev:

Coding challenges:

  • Create a for loop that iterates up to 100 while outputting "fizz" at multiples of 3, "buzz" at multiples of 5 and "fizzbuzz" at multiples of 3 and 5
  • duplicate([1,2,3,4,5]);// [1,2,3,4,5,1,2,3,4,5]
  • sort numbers in javascript(special case, requires callback function return a - b)
  • max using apply in javascript
  • [2, 5, 7] to [4, 10, 14] using array map
  • [3, 5, 6], [5, 8] => output 5 in javascript

Understanding of concepts

https://www.quora.com/How-do-you-judge-a-JavaScript-programmer-by-only-5-questions

  • I have an HTML table with five cells in it. Each cell has a button and a field. You do not have control over the HTML or naming conventions used for IDs, etc. Write an event handler that can be applied to each button which will call a function and write the result of that function to the field that is in the cell of the button that was clicked. Do not iterate over the cells of the table.
  • Explain to me how OOP works in JavaScript. This is going to involve a conversation about prototype inheritance, closures, and lexical scoping.
  • Give me an example of something that you would use a closure for - explain the closure you’ve written.
  • Describe how you would develop a single-page application without using a framework (this one is more of a discussion and covers performance and the memory leaks Dean mentioned).
  • JavaScript is a functional programming language. Give me an example of how you can use higher order functions in JavaScript to iterate over and apply a function to every element in an array. Do not use a for or while loop.
  • I need to be able to store a DOM element so that it may, based on the results of a LATER event be moved from one container element to another. For example, I need to create a button which removes an LI from an OL or UL. The element needs to be stored during the current session so that - based on the result of ANOTHER event, I can then either attach it to the second container, move it back to the first container, or discard it. (I’m interested in their knowledge of scoping in the session.. if they recommend a global, I’ll say ok, if we don’t want to use a global variable what other options do we have? This is not an over difficult question, but it allows you to see how they think when the obvious answer isn’t the best choice).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment