Oh! You closed up the window, so you cannot see raining

[Hugo] 使用 Hugo-notice

Shortcodes 介紹 Shortcodes 是內容檔案中的一個簡單片段,Hugo將使用預先定義的範本對其進行呈現。 除了更乾淨的 Markdown 外,Shortcodes 還可以隨時更新新的技術或標準。 Notice shortcodes 將以下程式碼加入到 Hugo 專案底下的 layouts/shortcodes/notice.html {{/* Available notice types: warning, info, note, tip */}} {{- $noticeType := .Get 0 | default "note" -}} {{/* Workaround markdownify inconsistency for single/multiple paragraphs */}} {{- $raw := (markdownify .Inner | chomp) -}} {{- $block := findRE "(?is)^<(?:address|article|aside|blockquote|canvas|dd|div|dl|dt|fieldset|figcaption|figure|footer|form|h(?:1|2|3|4|5|6)|header|hgroup|hr|li|main|nav|noscript|ol|output|p|pre|section|table|tfoot|ul|video)\\b" $raw 1 -}} {{/* Count how many times we've called this shortcode and load the css if it's the first time */}} {{- if not ($....

<span title='2024-01-19 01:26:30 +0800 +0800'>January 19, 2024</span>&nbsp;·&nbsp;2 min&nbsp;·&nbsp;Rain Hu

[Leetcode] Arrangement

題號 題目 類別 題解 1 Two Sum Hash Table Hash Table 2 Add Two numbers Linked List Recursion 201 Bitwise AND of Numbers Range Bitwise Operation Lowbit = x&(~x+1) 204 Count Primes Math Thetory The Sieve of Eratosthenes 408 Valid Word Abbreviation Two Pointers 字串轉數字

<span title='2023-10-06 16:30:47 +0800 +0800'>October 6, 2023</span>&nbsp;·&nbsp;1 min&nbsp;·&nbsp;Rain Hu

[Problem] Version Query

Version Query Hardness: \(\color{red}\textsf{Hard}\) Ralated Topics: Binary Search、Segment Tree、Heap (Priority Queue、Hash Table 一、題目 Given an information of application(APK) about its range of versions, find its corresponding OS version. If APK versions are probable for two or more OS versions, it must be belong to the latest OS version. The given apk_info structure is given as below. struct apk_info { int apk_version; int min_version = 1; int max_version = INT_MAX; }...

<span title='2022-10-20 22:29:15 +0800 +0800'>October 20, 2022</span>&nbsp;·&nbsp;4 min&nbsp;·&nbsp;Rain Hu