Top "Indexing" questions

Indexing data structures is a general technique to improve the speed of data lookups.

How to map with index in Ruby?

What is the easiest way to convert [x1, x2, x3, ... , xN] to [[x1, 2], [x2, 3], [x3, 4], ... , [xN, N+1]]

ruby arrays indexing
Why use the INCLUDE clause when creating an index?

While studying for the 70-433 exam I noticed you can create a covering index in one of the following two …

sql-server sql-server-2008 sql-server-2005 indexing
How to get indices of a sorted array in Python

I have a numerical list: myList = [1, 2, 3, 100, 5] Now if I sort this list to obtain [1, 2, 3, 5, 100]. What I want is the indices …

python indexing sorted
How to get row from R data.frame

I have a data.frame with column headers. How can I get a specific row from the data.frame as …

r indexing dataframe
Force index use in Oracle

I encountered this question in an interview and had no clue how to answer: There is a table which has …

sql oracle indexing sqlplus
How do you reindex an array in PHP but with indexes starting from 1?

I have the following array, which I would like to reindex so the keys are reversed (ideally starting at 1): Current …

php arrays indexing
How do MySQL indexes work?

I am really interested in how MySQL indexes work, more specifically, how can they return the data requested without scanning …

mysql indexing
Python: Find a substring in a string and returning the index of the substring

I have: a function: def find_str(s, char) and a string: "Happy Birthday", I essentially want to input "py" …

python string indexing substring
Get row-index values of Pandas DataFrame as list?

I'm probably using poor search terms when trying to find this answer. Right now, before indexing a DataFrame, I'm getting …

python list pandas indexing