Ray's blog
  • Home
  • Archives
  • Categories
  • Tags
  • About

Set Up a New Mac

Install Homebrew website 1/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" Install better terminal Install Iterm2 website ## Install Oh My Zsh
2025-05-22

Hello World

Welcome to Ray's website! This is my very first post!
2025-05-22

An interesting bug: function argument defined as a function

Yesterday I was having an interview with a company and they wanted me to write a tree structure and do a traverse on the tree. At first I wrote the following code: 123456789101112131415161718192021222
2025-03-29

LeetCode: 4, Median of Two Sorted Arrays

Intuition binary search on one of the array to find the correct position. Approach Complexity Time complexity: \(O(\log n)\) Space complexity: Code 1234567891011121314151617181920212223242526272
2025-02-16

LeetCode: 852. Peak Index in a Mountain Array

Intuition Use the tendence of the middle element to check either the required index is in the left or right of the middle element. Approach Complexity Time complexity: \(O(\log n)\) Space complexi
2025-02-13

Leetcode 1064. Fixed Point

Intuition Binary search on the array Approach If current index is less than arr[index], search for the left part, else search on the right part. If we find one, check if there are smaller ons by searc
2025-02-11

Theory of computation: nondeterministic finite automata

NFA and DFA are equavelent. The lembda edge can be replaced by a shortcut.
2025-02-04
Daily Logs > Computer Science > Theory of Computation
#Math #Proof Theory #Computer Science #Theory of Computation #Finite Automata #Nondeterministic Finite Automata

Website for downloading videos

I have tried several video downloading platform, this one works best so far: cobalt
2025-02-01
Daily Logs > Resources Share
#Resource Share

Theory of Computation: Finite Automata

Regular Expression I was wondering if the operation of regular expression (Union, Concatenation, Star) is complete. This question needs further prompt: In what sense do I mean complete? Am I asking: -
2025-01-30
Daily Logs > Computer Science > Theory of Computation
#Math #Proof Theory #Computer Science #Theory of Computation #Finite Automata #Regular Expression

understanding the halting problem

I was reading my Professor Richard Cole's note in the halting problem and I was confused on the statement for a while. Understanding the following two examples will help a lot in understanding the Hal
2025-01-23
Daily Logs > Math
#Math #Proof Theory #Computer Science #Theory of Computation
123…6

Search

Hexo Fluid
aggregate visit: times , people