The motivation for writing this book was the lack of resources available about data O. a! I% m9 Y, U% L" cstructures and algorithms written in JavaScript. This was strange to me because7 A# {) S$ ?5 I; A8 ?8 c
today many of the job opportunities for software development require knowledge of 1 W+ B( N( q- OJavaScript; it is the only language that can be used to write the entire stack, including the 4 F' \% x& O; Z8 jfront-end, mobile (native and hybrid) platforms, and back-end. It is crucial for JavaScript$ u+ S9 |5 H3 p7 M- [, q& P
developers to understand how data structures work and how to design algorithms to $ P/ y' w& }, r0 m# Z# }build applications. + A5 \% S2 D2 |$ Q n, tTherefore, this book aims to teach data structure and algorithm concepts from! G% S0 n7 ?1 K4 [
computer science for JavaScript rather than for the more typical Java or C++. Because# u# J; A$ q. V2 g' V+ e9 r E; O; C
JavaScript follows the prototypal inheritance pattern, unlike Java and C++ (which follow3 q- f% ^" N' s! q: G9 U
the inheritance pattern), there are some changes in writing data structures in JavaScript.0 f& w9 E5 ~6 t$ k/ J' T0 H+ N
The classical inheritance pattern allows inheritance by creating a blueprint-like ! L7 i( W9 o& ?4 bform& o7 `5 _: s) }9 u) T, |- l
that objects follow during inheritance. However, the prototypal inheritance pattern # N8 Y$ }. n# e) Zmeans copying the objects and changing their properties./ `. |7 @* { r, G
This book first covers fundamental mathematics for Big-O analysis and then lays out2 b8 l2 e1 \* r* Q
the basic JavaScript foundations, such as primitive objects and types. Then, this book 5 F. n4 a" _* D, {covers implementations and algorithms for fundamental data structures such as linked4 W8 i4 c9 r+ T! d( G
lists, stacks, trees, heaps, and graphs. Finally, more advanced topics such as efficient ! _7 h/ a- [' h a1 y$ zstring search algorithms, caching algorithms, and dynamic programming problems are 4 `3 P$ s; G# g4 [1 Yexplored in great detail.8 j5 v" I, z7 g$ D& @- x
- T" }/ G% h3 X" O
# ]! e9 V( y- I