Skip to content

Instantly share code, notes, and snippets.

View rohankandwal's full-sized avatar

Rohan Kandwal rohankandwal

  • Bengaluru, Karnataka, India
View GitHub Profile
# DSA Question Bank
## Arrays, Hashing, Prefix/Suffix
1. Find the second largest element in one pass without extra space.
2. Find the k largest distinct elements without fully sorting the array.
3. Find the two numbers that appear once when every other number appears twice.
4. Find the majority element that appears more than n / 2 times.
5. Find all elements that appear more than n / 3 times.
6. Count inversions in an array.
@rohankandwal
rohankandwal / analysis_options.yaml
Created March 10, 2022 09:40 — forked from crizant/analysis_options.yaml
Flutter linting rules
analyzer:
errors:
# treat missing required parameters as a warning (not a hint)
missing_required_param: warning
# treat missing returns as a warning (not a hint)
missing_return: warning
linter:
rules:
- always_declare_return_types