随笔分类 -  leetcode

自己对LeetCode上的题目的理解与解答,如有错误欢迎指正!
摘要:7. Reverse Integer Given a 32-bit signed integer, reverse digits of an integer. Example 1: Input: 123 Output: 321 Example 2: Input: -123 Output: -321 阅读全文
posted @ 2020-10-06 12:17 梅花五瓣 阅读(89) 评论(0) 推荐(0)
摘要:24. Swap Nodes in Pairs https://leetcode.com/problems/linked-list-cycle/ Given a linked list, swap every two adjacent nodes and return its head. You m 阅读全文
posted @ 2020-06-29 22:18 梅花五瓣 阅读(168) 评论(0) 推荐(0)
摘要:题目描述: Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the fart 阅读全文
posted @ 2019-05-03 23:54 梅花五瓣 阅读(95) 评论(0) 推荐(0)
摘要:101. Symmetric Tree 101. Symmetric Tree Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center). For example, th 阅读全文
posted @ 2019-03-27 21:28 梅花五瓣 阅读(135) 评论(0) 推荐(0)
摘要:100. Same Tree 100. Same Tree Given two binary trees, write a function to check if they are the same or not. Two binary trees are considered the same 阅读全文
posted @ 2019-03-20 11:17 梅花五瓣 阅读(100) 评论(0) 推荐(0)
摘要:1. Two Sum Given an array of integers, return indices of the two numbers such that they add up to a specific target.You may assume that each input wou 阅读全文
posted @ 2019-03-19 17:19 梅花五瓣 阅读(277) 评论(0) 推荐(0)