avatar
文章
823
标签
1101
分类
40
首页
主线
归档
标签
关于
家书
  • 父亲的与子书
  • 给女友的情书
LogoHespethornのBlog
搜索
首页
主线
归档
标签
关于
家书
  • 父亲的与子书
  • 给女友的情书

Leetcode-Python

Leetcode 0037.sudoku-solver(python)
发表于2024-05-30|AlgorithmsLeetcode-Python
37. Sudoku Solver题目Write a program to solve a Sudoku puzzle by filling the empty cells. A sudoku solution must satisfy all of the following rules: Each of t...
Leetcode 0036.valid-sudoku(python)
发表于2024-05-29|AlgorithmsLeetcode-Python
36. Valid Sudoku题目Determine if a 9 x 9 Sudoku board is valid. Only the filled cells need to be validated according to the following rules: Each row must con...
Leetcode 0032.longest-valid-parentheses(python)
发表于2024-05-28|AlgorithmsLeetcode-Python
32. Longest Valid Parentheses题目Given a string containing just the characters '(' and ')', find the length of the longest valid (well-formed) ...
Leetcode 0031.next-permutation(python)
发表于2024-05-27|AlgorithmsLeetcode-Python
31. Next Permutation题目A permutation of an array of integers is an arrangement of its members into a sequence or linear order. For example, for arr = [1,2,3],...
Leetcode 0030.Substring with Concatenation of All Words(python)
发表于2024-05-26|AlgorithmsLeetcode-Python
30. Substring with Concatenation of All Words一、问题描述给定一个字符串 s 和一个字符串数组 words,找出 s 中所有恰好由 words 中所有单词串联形成的子串的起始索引。 注意:words 中的单词可以以任意顺序串联。 示例 1: 示例 2: 示例...
Leetcode 0035.search-insert-position(python)
发表于2024-05-25|AlgorithmsLeetcode-Python
35. Search Insert Position题目Given a sorted array of distinct integers and a target value, return the index if the target is found. If not, return the index w...
Leetcode 0034.find-first-and-last-position-of-element-in-sorted-array(python)
发表于2024-05-24|AlgorithmsLeetcode-Python
34. Find First and Last Position of Element in Sorted Array题目Given an array of integers nums sorted in non-decreasing order, find the starting and ending pos...
Leetcode 0033.search-in-rotated-sorted-array(python)
发表于2024-05-23|AlgorithmsLeetcode-Python
33. Search in Rotated Sorted Array题目There is an integer array nums sorted in ascending order (with distinct values). Prior to being passed to your function, ...
Leetcode 0029.Divide Two Integers(python)
发表于2024-05-21|AlgorithmsLeetcode-Python
29. Divide Two Integers你选用何种方法解题?本题的核心是不使用乘法、除法和取模运算实现整数除法。 方法选择理由: 位运算(位移法):通过左移实现快速乘法,时间效率高 负数倍增法:使用负数处理避免溢出问题,更安全 解题过程问题分析输入:被除数 dividend,除数 divisor输...
Leetcode 0028.Implement strStr()(python)
发表于2024-05-16|AlgorithmsLeetcode-Python
28. Implement strStr()你选用何种方法解题?本题的核心是实现字符串匹配算法。 方法选择理由: 暴力匹配:代码简单,适合短字符串 KMP 算法:时间效率更高,适合长字符串 解题过程问题分析输入:主串 haystack,模式串 needle输出:needle 在 haystack 中第一...
Leetcode 0027.Remove Element(python)
发表于2024-05-11|AlgorithmsLeetcode-Python
27. Remove Element你选用何种方法解题?本题的核心是原地移除数组中等于给定值的元素。 方法选择理由: 快慢指针:只需一次遍历,空间复杂度 O(1) 解题过程问题分析输入:数组 nums,目标值 val输出:移除目标值后的数组长度 关键约束: 原地修改数组,不能使用额外空间 不需要保持元...
Leetcode 0026.Remove Duplicates from Sorted Array(python)
发表于2024-05-06|AlgorithmsLeetcode-Python
26. Remove Duplicates from Sorted Array你选用何种方法解题?本题的核心是原地删除有序数组中的重复元素。 方法选择理由: 快慢指针:只需一次遍历,空间复杂度 O(1) 解题过程问题分析输入:有序数组 nums输出:删除重复元素后的数组长度 关键约束: 原地修改数组,...
Leetcode 0025.Reverse Nodes in k-Group(python)
发表于2024-05-01|AlgorithmsLeetcode-Python
25. Reverse Nodes in k-Group题目Given the head of a linked list, reverse the nodes of the list k at a time, and return the modified list. k is a positive integ...
Leetcode 0024.Swap Nodes in Pairs(python)
发表于2024-04-26|AlgorithmsLeetcode-Python
24. Swap Nodes in Pairs题目Given a linked list, swap every two adjacent nodes and return its head. You must solve the problem without modifying the values in t...
Leetcode 0023.Merge k Sorted Lists(python)
发表于2024-04-21|AlgorithmsLeetcode-Python
23. Merge k Sorted Lists题目You are given an array of k linked-lists lists, each linked-list is sorted in ascending order. Merge all the linked-lists into one ...
123
avatar
Hespethorn
文章
823
标签
1101
分类
40
GitHub
fox
ciwei
最新文章
计算机原则五讲(一):这笔投入能换回什么2026-11-20
计算机原则五讲(三):责任放在哪一层2026-11-20
计算机原则五讲(二):故障发生时还剩什么保证2026-11-20
计算机原则五讲(五):规模一上来,系数说了算2026-11-20
计算机原则五讲(六):没有免费的优化2026-11-20
分类
  • AI-ML53
    • AI-App20
    • AI-News33
  • Algorithms219
    • DSA35
    • Leetcode-C++141
    • Leetcode-Mysql6
    • Leetcode-Python37
  • CS-Fundamentals41
    • CS501
    • CS61A20
    • CS61B20
  • CS-Principles13
  • Database20
    • Mysql5
标签
CS-Principles专栏介绍分治存储垃圾回收容错引用透明封装关注点分离逃逸分析分布式事务数据一致性安全工程算法分析网络协议操作系统软件测试语言运行时工程运维版本管理
归档
  • 2026年11月 20
  • 2026年10月 10
  • 2026年09月 53
  • 2026年08月 56
  • 2026年07月 38
  • 2026年06月 47
网站信息
文章数目 :
823
运行时间 :
本站总字数 :
1885.8k
最后更新时间 :
搜索
数据加载中