Zsh 简明配置指南
2024-10-21
config
zsh
作为计算机爱好者,我们每天会花大量时间和 Shell 打交道,一个配置得足够好的 Shell 会让你觉得更加得心应手。这篇博文记录了我的 Zsh 配置。本来,这篇文章只是作为我自己的笔记,所以写得比较随意;同时出于练习英语写作的目的,写成了英文。但后来发现我的朋友们也会参考,所以我将其重置为中文的,并修改完善了一些内容。
2024-10-21
config
zsh
作为计算机爱好者,我们每天会花大量时间和 Shell 打交道,一个配置得足够好的 Shell 会让你觉得更加得心应手。这篇博文记录了我的 Zsh 配置。本来,这篇文章只是作为我自己的笔记,所以写得比较随意;同时出于练习英语写作的目的,写成了英文。但后来发现我的朋友们也会参考,所以我将其重置为中文的,并修改完善了一些内容。
2024-10-18
vim
config
Vim 可以说是一个老古董了,但是在命令行文本编辑器这一领域,即使到目前,它说第二也没人能说第一。在这篇文章中,我们会进行一些简单的配置,让 Vim 更加好用。并且,我们还会谈到 NeoVim 相关的内容,通过安装和配置 LazyVim,来让 NeoVim 变为一个现代化的、全功能的 IDE。
2024-10-17
vue
web
本文介绍了如何使用 [Vue](https://cn.vuejs.org/) 和 [@vueuse/motion](https://motion.vueuse.org/) 创建一个带有动画的模态框。你可以在 [这里](https://github.com/BlockLune/modal-animation-demo/tree/main/modal-animation-demo-vue) 找到最终代码。
2024-10-17
rust
线程池是一种多线程处理形式,它通过将任务分配给事先创建好的线程以进行重用,提高了并发性能。本文是一篇阅读笔记,原材料为 [Rust 语言圣经 - 进阶实战 1 实现一个 Web 服务器](https://course.rs/advance-practice1/intro.html)。
2024-09-11
software engineering
mit 6.005
MIT 6.005 Spring 2016 的 [OCW](https://ocw.mit.edu/courses/6-005-software-construction-spring-2016/) 版本的学习笔记。此篇笔记涉及的内容为 Reading 4 Code Review。
2024-09-11
software engineering
mit 6.005
MIT 6.005 Spring 2016 的 [OCW](https://ocw.mit.edu/courses/6-005-software-construction-spring-2016/) 版本的学习笔记。此篇笔记涉及的内容为 Reading 3 Testing。
2024-09-06
react
next.js
这是一篇课堂笔记,课程为 Udemy [React - The Complete Guide 2024](https://www.udemy.com/course/react-the-complete-guide-incl-redux/)。该笔记包含了该课程中有关 NextJS 的部分内容。
2024-09-03
docker
容器化
devops
作为一个喜欢折腾新玩意儿的人,在网上冲浪时,我经常会去寻找各种各样新式的软件或服务。如果你和我一样也喜欢寻找这些软件,那你可能也会注意到,在安装指南中,越来越多的软件提供了一种使用 **Docker** 的安装或部署方法。这是什么东西?为什么现在流行使用它?我们又能如何使用它?这篇文章,带你入门 Docker 。
2024-09-02
environment
config
tutorial
guide
As developers, we interact with all kinds of machines every day. A well-configured development environment can significantly boost productivity and make coding more enjoyable. This comprehensive guide will help you set up a comfortable and efficient workspace. It's mainly for beginners, but experienced developers may also find some useful tips.
2024-03-09
gdb
gnu debugger
cheat sheet
The GNU debugger is a powerful tool for the debugging of (mainly) C/C++ programs. In this post I document the common operations of gdb and some useful learning resources.
2024-02-20
python
conda
pyenv
As a CS student, I often find myself working on projects that require different Python versions, each with its own set of dependencies and libraries. In such scenarios, having a reliable and efficient method for managing these versions becomes crucial. Inspired by _[pyenv 与 conda 双轨制:管理 Python 版本和环境](https://blog.yfi.moe/post/pyenv-conda-together/)_, this blog post aims to document my experience with managing multiple versions of Python using pyenv and conda.
2024-02-10
algorithm
coursera
note
shortest paths
This is a note for 4.4 Shortest Paths, _[Algorithms, Part II](https://www.coursera.org/learn/algorithms-part2/)_.
2024-02-08
chai
istanbul nyc
mocha
ts
test first programming
typescript
tsx
[Mocha](https://mochajs.org/) is a popular JS test framework, and [Istanbul](https://istanbul.js.org/) is a popular JS test coverage tool. How to use them when it comes to Typescript? This post shows a simple demo.
2024-02-04
hexo
plugin
I use Hexo with the NexT theme to build my blog. I wrote this plugin to solve a pain point I've encountered in this workflow.
2024-01-29
git
version control
Use remote servers to work with collaborators better.
2024-01-29
git
version control
Git's powerful branching and merging capabilities can help you deal with parallel collaborative development processes. Let's take a look.
2024-01-28
vim
vimgolf
[VimGolf.com](https://www.vimgolf.com/) is a good place for vimers to practice and improve their vim skills. This post records my experience of solving a very interesting VimGolf game -- [Quicksort](https://www.vimgolf.com/challenges/9v00651eb20100000000025b).
2024-01-27
git
version control
A Git commit message cheat sheet in Chinese.
2024-01-27
github
version control
I have posted a tutorial of Git (See _[Simple Git Tutorial](/posts/9363e311.html)_). But it mixed up using Git and using GitHub together. I post this new tutorial to draw a line and make things clear.
2024-01-26
html
js
vue.js
web
A simple two way binding example in vue3.
2023-12-03
compiling
cmake
Some simple CMake examples for reviewing.
2023-11-12
ai
kaggle
ml
note
This is a note for the course on Kaggle: _[Intro to Machine Learning](https://www.kaggle.com/learn/intro-to-machine-learning)_.
2023-10-17
python
object-oriented programming
translation
Chinese translation for _[Getter and Setter in Python](https://www.geeksforgeeks.org/getter-and-setter-in-python/)_.
2023-10-09
cli
This is a list of some awesome CLI (command-line interface) apps.
2023-08-14
ai
coursera
ml
machine learning specialization
note
python
tensorflow
This is a note for the [Machine Learning Specialization](https://www.coursera.org/specializations/machine-learning-introduction).
2023-08-09
ai
coursera
ml
machine learning specialization
note
numpy
python
vectorization
This is a note for the [Machine Learning Specialization](https://www.coursera.org/specializations/machine-learning-introduction).
2023-08-05
tmux
Notes for _tmux Productive Mouse-Free Development_ written by Brian P. Hogan.
2023-08-04
tmux
Chinese translation for _[How to Install and Use Tmux](https://tmuxcheatsheet.com/how-to-install-tmux/)_.
2023-08-03
algorithm
coursera
minimum spanning trees
note
This is a note for 4.3 Minimum Spanning Trees, _[Algorithms, Part II](https://www.coursera.org/learn/algorithms-part2/)_.
2023-07-29
algorithm
bfs
coursera
dfs
directed graph
note
strong components
topological sort
This is a note for 4.2 Directed Graphs, _[Algorithms, Part II](https://www.coursera.org/learn/algorithms-part2/)_.
2023-07-27
algorithm
bfs
connected component
coursera
dfs
euler cycle
euler tour
note
undirected graph
This is a note for 4.1 Undirected Graphs, _[Algorithms, Part II](https://www.coursera.org/learn/algorithms-part2/)_.
2023-07-19
coursera
nand2tetris
virtual machine
stack arithmetic
note
This is a note for Nand2Tetris unit 7 (Part II, Unit 1).
2023-07-17
coursera
nand2tetris
assembler
assembly language
note
This is a note for Nand2Tetris Unit 6.
2023-07-14
ai
andrew ng
ml
note
Here are my notes for course [Machine Learning](https://study.163.com/course/courseMain.htm?courseId=1210076550) taught by Andrew Ng. About exercise: I didn't do the original version exercise which depends on Octave or Matlab, but a third-party Python version (See [nsoojin/coursera-ml-py](https://github.com/nsoojin/coursera-ml-py)).
2023-07-12
coursera
nand2tetris
computer architecture
fetch-execute cycle
date bus
instruction bus
cpu
computer design
note
This is a note for Nand2Tetris Unit 5.
2023-07-12
joshuto
When in a terminal, sometimes it's really annoying to keep on typing in `cd` or something else to browse the files and directories. Can we do it just like what we do in GUI? Then joshuto may be helpful to you.
2023-07-11
coursera
nand2tetris
assembly language
machine language
note
This is a note for Nand2Tetris unit 4.
2023-07-09
coursera
nand2tetris
memory
ram
register
counter
sequential logic
dff
note
This is a note for Nand2Tetris unit 3.
2023-07-08
coursera
nand2tetris
boolean arithmetic
alu
note
This is a note for Nand2Tetris Unit 2.
2023-07-08
nand2tetris
boolean functions
gate logic
note
This is a note for Nand2Tetris Unit 1.
2023-07-07
python
cs50p
pip
This is a list of some Python libraries mentioned in CS50P 2022.
2023-07-04
regexp
ipv4
While solving [the NUM3RS problem of CS50P](https://cs50.harvard.edu/python/2022/psets/7/numb3rs/), I was asked to match IPv4 addresses with RegExp.
2023-06-29
python
matplotlib
Here are some notes for Matplotlib.
2023-06-22
windows
When the Windows system was updated to version 11, the right-click menu was completely redesigned. Microsoft is apparently trying to make it simpler and more modern, but the way they have chosen to do it is really brute force: hiding everything useful in the secondary menu! I find this really annoying. Luckily, we have a way to bring back the classic, and even customize it and make it better! (This post is in Chinese.)
2023-06-01
c & c++
cs106l
online course summary
This is [CS106L](https://web.stanford.edu/class/cs106l/index.html), an in-depth modern C++ language course from Stanford. I enrolled in it at the beginning of April and almost finished it today.
2023-06-01
c & c++
const
cs106l
note
This is a note for Lecture 8, [CS106L](https://web.stanford.edu/class/cs106l/index.html), Spring 2023.
2023-05-31
c & c++
cs106l
note
This is a note for Lecture 14, [CS106L](https://web.stanford.edu/class/cs106l/index.html), Spring 2023.
2023-05-30
cs106l
c & c++
note
This is a note for Lecture 13, [CS106L](https://web.stanford.edu/class/cs106l/index.html), Spring 2023.
2023-05-30
cs106l
c & c++
const
This is a note for Lecture 8, [CS106L](https://web.stanford.edu/class/cs106l/index.html), Spring 2023.
2023-05-28
python
itertools
Extracted from _[itertools — Functions creating iterators for efficient looping — Python 3.11.3 documentation](https://docs.python.org/3/library/itertools.html)_
2023-05-12
coursera
algorithm
online course summary
As the title says, this is my personal summary of [Algorithms, Part I](https://www.coursera.org/learn/algorithms-part1) on [Coursera](https://www.coursera.org).
2023-04-27
linux
This is NOT a tutorial on how to install Ubuntu. I am just documenting some problems I encountered during my installation.
2023-04-15
web
hexo
This is a simple record of my further attempt to set up a blog with Hexo. I built one on GitHub Page before, using Hexo with the Icarus theme. This time I want to try something different. I also cleaned up my old blog and selectively migrated some old posts here.
2023-03-25
c & c++
I used to control users' input by making the input a string and process it later. But today, my friend posed this question to me: Can we control input without a char array or string class?
2023-03-24
c & c++
const
I have written a post about `const` in C++ in Chinese before, but [it](/posts/7ec6ba38.html) was too verbose and unclear. :( So, I decided to rewrite it.
2023-03-23
linux
chmod
I accidentally ran a wrong `chmod` command in my Linux, and it messed up everything! I hate the permission management in Linux. :|
2023-03-15
java
A simple conclusion of some useful packages in java.
2023-03-11
git
github
version control
vcs
This is mainly a simple tutorial of Git. Some info about GitHub also included. You may also read _[Simple GitHub Tutorial](/posts/1cce885f.html)_.
2023-03-11
linux
package manager
archlinux
ubuntu
pacman
apt
This post tries to simply introduce some package managers and their basic usage.
2023-01-13
vs code
很多时候我们会避免一行代码过长,常见的限制有 80 字符、120 个字符等。我希望能在 VS Code 中显示一条边界线来提醒我已经到达这个限制了,需要换行。下边是设置的方法。
2023-01-12
c & c++
file
简单记录一下 C 语言的文件操作的相关内容。
2023-01-11
issue
solved
debug
lldb
llvm
clang
直接先说解决方法:在使用 clang 工具链进行编译的时候,添加编译选项 `-fstandalone-debug`。
2023-01-08
makefile
gnu make
compiling
这是一篇笔记,原视频是 [@于仕琪](https://space.bilibili.com/519963684) 老师的 [《Makefile 20 分钟入门,简简单单,展示如何使用 Makefile 管理和编译 C++ 代码》](https://www.bilibili.com/video/BV188411L7d2)。
2022-12-08
sorting
c & c++
stl
虽然到现在还是不能完全理解 `qsort` 和 `sort` 这两个函数的底层原理,但至少,先学会如何使用吧。
2022-12-04
gcd
algorithm
这是一次计算机导论课的作业。本来对于最大公约数的求解算法,我就只知道一个**辗转相除法**。原来,其实还有别的一些 ...
2022-11-22
algorithm
bfs
dfs
note
searching
**深度优先搜索**(DFS,Depth First Search)和**广度优先搜索**(BFS,Breadth First Search),我从来没弄明白过。是时候努力去好好理解一下了。
2022-11-17
c & c++
const
最开始只是用 const 来定义常量,学到了指针传参的时候又知道了用 const 来防止一些值的修改,学到类的时候又看到非静态成员函数后边加个 const 来干嘛干嘛,然后么又听说什么顶层 const、底层 const... 真是越学越迷糊了,赶紧做一波整理。
2022-11-16
c & c++
array
pointer
一维数组还是比较容易理解的,但是二维数组,我始终没弄清楚这玩意儿是按照什么规则从二维的样子转成一维然后存起来的,也因此常常犯下下标写反了的错误。我觉得是时候详细地理一理这玩意儿到底是个啥了...
2022-11-16
c & c++
pointer
接[《一个有关指针传参的问题》](/posts/50c16b14.html),再理一理这里边的一些问题...
2022-11-05
c & c++
这事儿要从一周前讲起,有人在群里问了这么一道题,要求用 C 实现:
2022-11-05
c & c++
pass by value
pass by pointer
pass by reference
接上文[《一个有关指针传参的问题》](/posts/50c16b14.html),打算结合一些简单的例子系统地梳理一下 C/C++ 中的值传递、指针传递和 C++ 中特有的 引用传递。
2022-11-03
c & c++
pointer
pass by pointer
pass by value
issue
solved
这是我学习指针过程中遇到的一个问题,问过大佬才似乎懂了点,在此记录。顺便记下一句大佬说的话: > 注意到一点就行,指针其实也就是个存了内存地址的变量,**它本身同时也具有内存地址**。
2022-10-27
c & c++
我曾经一直以为 C/C++ 中赋值语句的返回值不是 0 就是 1 —— 成功执行赋值操作返回 1,没有成功执行就返回 0。直到今天课上的一个例子,才让我知道,原来**赋值语句的返回值就是赋的值的大小**!
2022-10-19
iomanip
c & c++
本文汇总一下 C 语言 `scanf` 和 `printf` 的格式控制方法以及 C++ 的 `<iomanip>` 库。
2022-10-15
novelai
ai
最近一段时间,感觉突然之间,就有很多很多将现实图片二次元化啊,按照每句歌词生成一副画作啊的 AI 绘画应用的图文视频出现。和室友聊天还说是不是最近一段时间 AI 技术突破什么瓶颈突飞猛进了。后来才知道,原来是 NovelAI 泄露了... 这样一来,本地部署方便了起来,于是整了一个玩玩。由于跑 AI 嘛,GPU 比较呼啸,跟挖矿一样,我就戏称我这是在“挖老婆矿”了。
2022-10-13
vs code
c & c++
**2023 年 1 月 12 日更新:** 找到了方便地改变 Windows 中终端默认编码的方法,所以原来的改变 C/C++ 文件默认编码的方法可以淘汰了。
2022-10-11
c & c++
此篇笔记来源于下边的这个题目。 ![](https://b316f18.webp.li/blog-imgs/cs/languages/c%20&%20cpp/c-语言中与-和或-运算符的短路运算/1.png)
2022-10-06
c & c++
game
校科协的加入有条件,面试前一步是笔试。免去笔试的方法也不是没有,可以做免试题。看了各个组的免试题,发现都好难好难,只有前端组的 2048 敢去尝试尝试。但我有没怎么学过 JS,便想着先用 C++ 实现一下逻辑,再把代码改过去。
2022-09-29
c & c++
笔者的朋友有道输入八进制输出十进制的题目,他是使用数学方法实现的。笔者隐隐约约记得好像cin和cout有控制输入输出数字进制的方法,查找了一些资料,做一下笔记。
2022-09-17
vs code
c & c++
我以前学习 C++ 的时候,使用的是 DevCpp 。这个软件让我这个初学者比较舒服的点是,我不用太过详细地考虑编译的过程——新建一个 cpp 文件,写一点小程序,按下 F11,程序运行。我不需要管选择编译器啊、配置编译命令啊啥啥的。但是到 VS Code 这边,这都要我自己做了,对于新手并不是那么友好。这里记录一下我配置 VS Code 的 C/C++ 环境的完整过程,希望对你有所帮助。需要注意的是:学习一下基本的编译链接指令还是很有必要的!
2022-09-15
mathematics
latex
用 LaTeX 写数学公式的时候,总记不住一些写法,故在此记录学习笔记。
2022-08-26
vue.js
element ui
html
js
web
这件事儿发生在我的高中某个新学期开始,新来了一个电脑老师。有点打赌或者考验我的性质吧,ta 说 ta 弄了随机数点名的小网页,还能用同学的照片进行抽取,问我能不能实现一个。ta 的实现方法是 jQuery,技术上比较老,界面也不太好看。我想去尝试一下别的方法,正好也试试略微学了一点的 Vue.js,为了好看,用了 Element UI。
2022-08-25
edge
browser
2019 年 7 月写过一篇 Chrome 插件推荐的文章,那时候我还在用 Chrome 作为我的主要浏览器。一晃三年过去了,我也早已从 Google Chrome 转入全新 Chromium 内核构建的 Edge 浏览器。微软倒蛮有意思,自己从头开发的东西不咋地,在别人的平台上倒是表现得相当好。由于国内的水土不服啊,我用 Chrome 时总会遇到同步不了的情况,这点的体验在 Edge 这儿得到了很好的改善,也是我用 Edge 的主要原因吧。前些天帮很多同学做新机开荒,也推荐他们就用这款“Win11 原装”浏览器。当然一个浏览器肯定是离不开扩展的,趁着帮他们开荒这个机会,也顺便整理了我认为必备的一些浏览器扩展。
2019-07-13
chrome
browser
你可能常年使用着国产的一些浏览器,却也常年遭受着各种弹窗、全家桶的侵扰... 你也可能不止一次地听过"Chrome",安装下来后却发现他空空如也,又默默地装回那些国产... 那么,让这些插件来拯救你吧