About 12,200,000 results
Open links in new tab
  1. How to create an array containing 1...N

    We'll use that fact later. Array.apply(null, [undefined, undefined, undefined]) is equivalent to Array(undefined, undefined, undefined), which produces a three-element array and assigns …

  2. Array increment positioning with respect to indexer in C - array [i ...

    Apr 26, 2023 · An illustration. Suppose that array contains three integers, 0, 1, 2, and that i is equal to 1. array[i]++ changes array[1] to 2, evaluates to 1 and leaves i equal to 1. array[i++] …

  3. How can I initialize all members of an array to the same value?

    How would you use memset to initialize a int array to some value larger than 255? memset only works if the array is byte sized.

  4. How do I declare an array in Python? - Stack Overflow

    Aug 23, 2022 · The array structure has stricter rules than a list or np.array, and this can reduce errors and make debugging easier, especially when working with numerical data.

  5. A confusion about ${array[*]} versus ${array[@]} in the context of a ...

    The difference between [@] and [*] -expanded arrays in double-quotes is that "${myarray[@]}" leads to each element of the array being treated as a separate shell-word, while …

  6. How to make an array of arrays in Java - Stack Overflow

    How to make an array of arrays in Java Asked 14 years, 10 months ago Modified 8 years, 4 months ago Viewed 476k times

  7. Remove duplicate values from a JavaScript array

    If you want to remove objects from an array that have exactly the same properties and values as other objects in the array, you would need to write a custom equality checking function to …

  8. Which comes first in a 2D array, rows or columns?

    Jul 25, 2012 · When creating a 2D array, how does one remember whether rows or columns are specified first?

  9. Check if an element is present in an array [duplicate]

    Of course, if your array is sorted you could do a binary-search instead. Or if each value in the array is always unique you could use a map-based approach instead.

  10. Loop through an array of strings in Bash? - Stack Overflow

    Jan 16, 2012 · Without them, the for loop will break up the array by substrings separated by any spaces within the strings instead of by whole string elements within the array. ie: if you had …