Author: admin

  • Web browser: Cookies

    Cookies Cookies are a concept in web development that involves small pieces of data stored by the browser, which are sent back to the server with each HTTP request. This feature is commonly used for session management, tracking user behavior, and storing user-specific information, such as login credentials or preferences.…

  • Web browser: IndexedDB

    IndexedDB IndexedDB is a concept in web development that provides a low-level API for storing large amounts of structured data in the browser. This feature allows for complex queries and transactions, making it suitable for storing significant amounts of data, such as large files and structured data, in a way…

  • Web browser: Session Storage

    Session Storage Session storage is a concept in web development that is similar to local storage but with a key difference: data stored in session storage is only available for the duration of the page session. This means that once the tab or window is closed, the data is automatically…

  • Web browser: Local Storage

    Local Storage Local storage is a concept in web development that allows websites to store data as key-value pairs in the browser with no expiration time. This feature can retain data even after the browser is closed and reopened, making it useful for storing information that needs to persist across…

  • Web browser: Chrome Storage Item

    Chrome Storage Item Local Storage and Session Storage are suitable for simpler key-value pairs but differ in persistence. IndexedDB is ideal for large, complex datasets and is designed to work asynchronously for better performance. Cookies are small, automatically sent with HTTP requests, and used for session management but have limited…

  • LeetCode: 3 Longest Substring Without Repeating Characters

    Given a string s, find the length of the longest substring without repeating characters. Example: Input: s = "abcabcbb" Output: 3 Explanation: The answer is "abc", with the length of 3. Example: Input: s = "bbbbb" Output: 1 Explanation: The answer is "b", with the length of 1. 问题 给定一个字符串…

  • Git 101: Git Command Cheat Sheet

    Here’s a comprehensive table of Git commands based on the above contents, including explanations and code examples: Git Command Cheat Sheet Command Description in English Description in Chinese Code Example git init Initializes a new Git repository in the current directory 在当前目录中初始化一个新的Git仓库 git init git status Shows the status of…

  • Algorithms 101: Circular Queue Implementation Using Array

    环形队列用数组实现 Circular Queue Implementation Using Array A circular queue is a more efficient implementation of a queue using an array, where the end of the array wraps around to the beginning. This avoids the need to shift elements and allows the queue to efficiently utilize space. Unlike a traditional linear…

  • Algorithms 101: Stack Implementation Using Array

    栈的数组实现 Stack Implementation Using Array A stack can be implemented using an array where the push operation adds an element to the end of the array (top of the stack), and the pop operation removes the element from the end. This implementation is simple and leverages the dynamic resizing capabilities…

  • Algorithms 101: Queue Implementation Using Linked List and Array

    队列的链表实现和数组实现 Queue Implementation Using Linked List and Array 1. 使用链表实现队列 1. Queue Implementation Using Linked List A queue can be implemented using a linked list where each node represents an element in the queue. The head of the linked list represents the front of the queue, and the tail represents…