1. Remove duplicates from a sorted array and return the new length.
2. Find the maximum number of consecutive 1s in a binary array.
3. Check if a given string is a palindrome, ignoring non-alphanumeric characters.
4. Find two lines in an array of heights that form a container with the most water.
5. Return the intersection of two arrays.
6. Determine if a number is a happy number.
7. Find the minimal length of a contiguous subarray whose sum is at least s.
8. Find all unique triplets in an array that sum up to zero.
9. Given a sorted array, determine indices of two numbers that add up to a specific target.
10. Sort an array containing red, white, and blue in place.
11. Find the length of the longest substring without repeating characters.
12. Check if two strings are anagrams of each other.
13. Find all starting indices of a permutation in a string.
14. Find the contiguous subarray with the largest product.
15. Rotate an array to the right by k steps.
16. Check if a linked list is a palindrome.
17. Find the longest palindromic substring in a given string.
18. Find the duplicate number in an array of n + 1 integers.
19. Return a new array containing the squares of a sorted array in non-decreasing order.
20. Find the minimum window substring of a given string that contains all characters of another string.
21. Merge two sorted arrays.
22. Count the number of islands in a 2D grid.
23. Find the longest common prefix string amongst an array of strings.
24. Reverse a string using two pointers.
25. Check if a string can be rearranged to form a palindrome.
26. Find the number of pairs in an array that sum up to a target.
27. Rotate a linked list to the right by k places.
28. Find the first non-repeating character in a string.
29. Merge two sorted linked lists.
30. Find the longest substring that contains at most k distinct characters.
31. Implement a basic calculator with two pointers.
32. Check if a sequence can be formed by a valid parenthesis string.
33. Find the longest valid parentheses substring.
34. Given two strings, determine if they are one edit away.
35. Find the minimum number of steps to make two strings equal.
36. Count how many unique characters exist between two strings.
37. Given an array, check if it can be partitioned into two subsets with equal sum.
38. Implement an algorithm to reverse words in a given string.
39. Find the maximum sum of a subarray of size k.
40. Check if a given number is a perfect square.