@shahwar01
Coder
Nothing here yet.
Nothing here yet.
Dec 26, 2025 · 2 min read · Problem: https://leetcode.com/problems/rearrange-array-elements-by-sign/ Code: class Solution: def rearrangeArray(self, nums: List[int]) -> List[int]: non_neg_nums = [] neg_nums = [] result = [] # Segregated non-n...
Join discussionDec 22, 2025 · 4 min read · Problem: https://leetcode.com/problems/repeated-substring-pattern/ Code: class Solution: def repeatedSubstringPattern(self, s: str) -> bool: return s in (s + s)[1:-1] # Points to note: # - A repeated string will reappear ...
Join discussion