随笔分类 -  LeetCode

摘要:Count Binary Palindromic Numbers You are given a non-negative integer n. A non-negative integer is called binary-palindromic if its binary representat 阅读全文
posted @ 2025-09-10 23:21 onlyblues 阅读(29) 评论(0) 推荐(0)
摘要:Minimum Operations to Equalize Binary String You are given a binary string s, and an integer k. In one operation, you must choose exactly k different  阅读全文
posted @ 2025-09-02 16:19 onlyblues 阅读(64) 评论(0) 推荐(0)
摘要:Two-Letter Card Game You are given a deck of cards represented by a string array cards, and each card displays two lowercase letters. You are also giv 阅读全文
posted @ 2025-08-31 23:14 onlyblues 阅读(18) 评论(0) 推荐(0)
摘要:Count the Number of Arrays with K Matching Adjacent Elements You are given three integers n, m, k. A good array arr of size n is defined as follows: E 阅读全文
posted @ 2025-06-20 22:01 onlyblues 阅读(76) 评论(0) 推荐(0)
摘要:Path Existence Queries in a Graph II You are given an integer n representing the number of nodes in a graph, labeled from 0 to n - 1. You are also giv 阅读全文
posted @ 2025-04-30 13:30 onlyblues 阅读(43) 评论(0) 推荐(0)
摘要:Find X Value of Array II You are given an array of positive integers nums and a positive integer k. You are also given a 2D array queries, where queri 阅读全文
posted @ 2025-04-20 18:05 onlyblues 阅读(16) 评论(0) 推荐(0)
摘要:Maximum Product of Subsequences With an Alternating Sum Equal to K You are given an integer array nums and two integers, k and limit. Your task is to 阅读全文
posted @ 2025-04-08 09:53 onlyblues 阅读(126) 评论(0) 推荐(0)
摘要:Check If Digits Are Equal in String After Operations II You are given a string s consisting of digits. Perform the following operation repeatedly unti 阅读全文
posted @ 2025-02-24 11:12 onlyblues 阅读(42) 评论(0) 推荐(0)
摘要:Maximum Difference Between Even and Odd Frequency II You are given a string s and an integer k. Your task is to find the maximum difference between th 阅读全文
posted @ 2025-02-02 21:33 onlyblues 阅读(107) 评论(0) 推荐(0)
摘要:Minimum Operations to Make Character Frequencies Equal You are given a string s. A string t is called good if all characters of t occur the same numbe 阅读全文
posted @ 2024-12-16 22:50 onlyblues 阅读(45) 评论(0) 推荐(0)
摘要:Maximum Area Rectangle With Point Constraints II There are n points on an infinite plane. You are given two integer arrays xCoord and yCoord where (xC 阅读全文
posted @ 2024-12-09 23:04 onlyblues 阅读(167) 评论(0) 推荐(0)
摘要:Find Products of Elements of Big Array A powerful array for an integer x is the shortest sorted array of powers of two that sum up to x. For example, 阅读全文
posted @ 2024-05-13 17:09 onlyblues 阅读(13) 评论(0) 推荐(0)
摘要:Find All Possible Stable Binary Arrays II You are given 3 positive integers zero, one, and limit. A binary array arr is called stable if: The number o 阅读全文
posted @ 2024-04-28 23:56 onlyblues 阅读(41) 评论(0) 推荐(0)
摘要:Count Valid Paths in a Tree There is an undirected tree with n nodes labeled from 1 to n. You are given the integer n and a 2D integer array edges of 阅读全文
posted @ 2024-03-10 20:43 onlyblues 阅读(31) 评论(0) 推荐(0)
摘要:Minimize OR of Remaining Elements Using Operations You are given a 0-indexed integer array nums and an integer k. In one operation, you can pick any i 阅读全文
posted @ 2024-02-17 16:54 onlyblues 阅读(21) 评论(0) 推荐(0)
摘要:Count Beautiful Substrings II You are given a string s and a positive integer k. Let vowels and consonants be the number of vowels and consonants in a 阅读全文
posted @ 2023-11-28 09:17 onlyblues 阅读(44) 评论(0) 推荐(0)
摘要:Make Lexicographically Smallest Array by Swapping Elements You are given a 0-indexed array of positive integers nums and a positive integer limit. In 阅读全文
posted @ 2023-11-28 09:17 onlyblues 阅读(84) 评论(0) 推荐(0)
摘要:Minimum Changes to Make K Semi-palindromes Given a string s and an integer k, partition s into k substrings such that the sum of the number of letter 阅读全文
posted @ 2023-10-24 16:16 onlyblues 阅读(36) 评论(0) 推荐(0)
摘要:Count of Sub-Multisets With Bounded Sum You are given a 0-indexed array nums of non-negative integers, and two integers l and r. Return the count of s 阅读全文
posted @ 2023-10-15 18:08 onlyblues 阅读(109) 评论(0) 推荐(0)
摘要:String Transformation You are given two strings s and t of equal length n. You can perform the following operation on the string s: Remove a suffix of 阅读全文
posted @ 2023-09-10 20:52 onlyblues 阅读(35) 评论(0) 推荐(0)

Web Analytics