Microsoft Interview Question
Applications DevelopersCountry: United States
Interview Type: Phone Interview
From wiki: A time series is a sequence of data points, measured typically at successive points in time spaced at uniform time intervals.
Use two arrays of the same length to store your time series. The first array stores values (e.g. price) and the seconds stores time. Note that the second series is monotonically increasing (or at least non-decreasing), i.e. it's sorted. This property enables you to search it using the binary search algorithm. Once you get an index of a time of interest in the second array you also have the index of the relevant entry in the first array. If you wrap the two arrays and the search algorithm e.g. in a class you will have the whole implementation complexity hidden behind a simple interface.
please, can you give some example of time series?
- glebstepanov1992 December 17, 2013