Skip to content

Problems on Arrays #26

Description

@sachinpathakvns
  1. Check if two arrays are equal or not
  2. First element to occur k times
  3. Convert the array into a Zig-Zag fashion
  4. Subarray with given sum
  5. Missing number in array
  6. Sort an array of 0s, 1s, and 2s
  7. Leaders in an array
  8. Equilibrium Point
    The equilibrium Point in an array is a position such that the sum of elements before it equals the sum of elements after it.
  9. Stock buy and sell
    The cost of stock on each day is given in an array A[] of size N. Find all the segments of days on which you buy and sell the stock so that in between those days for which profit can be generated
  10. Largest subarray with 0 sum
  11. Array Subset of another array
  12. Longest Common Prefix in an Array
  13. Find all pairs with a given sum
  14. Kadane's Algorithm
    Given an array Arr[] of N integers. Find the contiguous sub-array(containing at least one number) which has the maximum sum and return its sum.
  15. Minimum number of jumps
  16. Trapping Rain Water
    Given an array arr[] of N non-negative integers representing the height of blocks. If the width of each block is 1, compute how much water can be trapped between the blocks during the rainy season.
  17. Rearrange Array Alternately
  18. Minimum Swaps to Sort
  19. Largest Number formed from an Array

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions