Мазмұнға өту

LeetCode

Шешкен есептерім және олар туралы жазбалар: тәсіл, жіберген қателерім және тағы нені пысықтау керек.

LeetCode-та шешілгені

43есеп шешілді

Жеңіл
31
Орташа
11
Қиын
1

Деректер:

Есеп талдаулары 4

Талдаулар ағылшын тілінде жазылған.

  • 20.Valid ParenthesesЖеңіл

    Given a string of ()[]{} characters, decide whether every bracket is closed by the same type of bracket, in the right order.

    stack matching

  • Merge two sorted linked lists into one sorted list by splicing their nodes together, and return its head.

    two pointers + dummy node

  • Given a string s, reverse the order of the words (not characters). Words are separated by spaces; input may contain leading/trailing/multiple spaces which must be collapsed into single spaces in the output.

    string split / two pointers

  • 206.Reverse Linked ListЖеңіл

    Reverse a singly linked list and return the new head.

    in-place pointer reversal