📜 ⬆️ ⬇️

Cheat Sheet for Technical Interview


This cheat sheet will help you prepare for a technical interview so you can brush up on key things. In fact, this is the content of the course on computer science without any details.


Basics of data structures


Array


Definition:



What you need to know:



Efficiency ("O" large) :



Linked list


Definition:



What you need to know:



Efficiency ("O" large):



Hash table


Definition:



What you need to know:



Efficiency ("O" large):



Binary tree


Definition:



What you need to know:



Efficiency ("O" large):



Search


Search wide


Definition:



What you need to know:



Efficiency ("O" large):



Depth search


Definition:



What you need to know:



Efficiency ("O" large):



Comparison of searches in width and in depth



Nuances:



Efficient sorting


Merge sort


Definition:



What you need to know:



Efficiency ("O" large):



Quick sort


Definition:



What you need to know:



Efficiency ("O" large):



Bubble Sort


Definition:



What you need to know:



Efficiency ("O" large):



Comparison of merge sorting and quick sorting algorithms



The main types of algorithms


Recursive algorithms


Definition:



What you need to know:



Iterative Algorithms


Definition:



What you need to know:



Comparing recursiveness and iteration



Pseudocode for traversing an array (which is why iteration is used for this)


  |  ----------------------------------|---------------------------------- recursive method (array, n) | iterative method (array) if array[n] is not nil | for n from 0 to size of array print array[n] | print(array[n]) recursive method(array, n+1) | else | exit loop | 

Greedy


Definition:



What you need to know:



Pseudo-code greedy algorithm for finding the biggest difference between two numbers in an array


 greedy algorithm (array) var largest difference = 0 var new difference = find next difference (array[n], array[n+1]) largest difference = new difference if new difference is > largest difference repeat above two steps until all differences have been found return largest difference 

This algorithm does not need to compare with each other all the differences, which saves us a whole iteration.


')

Source: https://habr.com/ru/post/350326/


All Articles