Docsity

Data Structures and Algorithms with Javascript, Exams of Data Structures and Algorithms

Toggle sidebar
bg1
Data Structures and
Algorithms with Javascript
How can you implement a matrix in javascript? - ANSan array of arrays
What array method allows us to add an element to the end? - ANSpush
What array method allows us to insert an element in the beginning of an
array? - ANSunshift
What array method allows us to remove an element by simply specifying the
position/index, and how many elements we would like to remove? -
ANSsplice
What array method allows us to remove an element in the beginning of an
array? - ANSshift
What array method allows us to remove an element in the end of an array? -
ANSpop
What array method will iterate each element of the array until the return of
the function is false? - ANSevery
What do the shift and unshift methods allow an array to emulate? -
ANSqueue
What is a data structure where we can have rows and columns? - ANStwo-
dimensional array
pf2

Partial preview of the text

Download Data Structures and Algorithms with Javascript and more Exams Data Structures and Algorithms in PDF only on Docsity!

Data Structures and

Algorithms with Javascript

How can you implement a matrix in javascript? - ANSan array of arrays What array method allows us to add an element to the end? - ANSpush What array method allows us to insert an element in the beginning of an array? - ANSunshift What array method allows us to remove an element by simply specifying the position/index, and how many elements we would like to remove? - ANSsplice What array method allows us to remove an element in the beginning of an array? - ANSshift What array method allows us to remove an element in the end of an array? - ANSpop What array method will iterate each element of the array until the return of the function is false? - ANSevery What do the shift and unshift methods allow an array to emulate? - ANSqueue What is a data structure where we can have rows and columns? - ANStwo- dimensional array

What is another name for a two-dimensional array? - ANSmatrix What method joins two arrays together? - ANSconcat What stores a sequence of values that are all of the same data type? - ANSarray