Sorting Algorithm
Today, I’m learning sorting algorithm, and taking some notes in this passage. Selection SortI believe Selection Sort is the easiest sorting algorithm to understand, as it simply involves repeatedly finding the smallest elements in the unsorted portion of the array and swapping it with the first unsorted element.   Let’s take a look at the implementation: Implementation12345678910111213141516/* Section Sort */void section_sort(int *nums, int numsSize) {  // Outer loop: i represents the...
Configing My Arch
In the last passage, I have talked about my experience of installing the basic system of Arch Linux.Ok, now we have Installed the base system of archlinux, and here it’s time to do some basic configurations.首先启动到 arch 系统,登录 root 账户。 创建普通账户啥事都用 root 用户做的话是有风险的,并且很多软件对于 root 用户是有限制的。所以当然,我们需要有一个普通账户 123[root]# useradd -m <username>...[root]# passwd <username>  上述命令创建一个名为 username 的用户,并且为其创建用户目录。 创建用户之后可以使用 su <username> 命令切换到新创建的用户 配置 sudosudo 可以让我们很方便地进行高权限操作。输入下列命令,使用 vim...
My experience using archlinux
最近安装了一个 archlinux 玩玩, 发现真的挺麻烦的。我反复安装过几次,在这里记录一下我安装和配置基本系统的经历。 关于安装 arch 的一些建议arch 有非常完善,非常强大的 wiki 文档以及社区,在其中可以找到很多很多的帮助:arch 的 wiki 系统的安装安装一个系统,首先要制作一个安装介质,比如 USB 驱动器。 制作 USB flash drive制作 archlinux 安装介质(USB 驱动器)的步骤:    准备一个大小至少 2GB 的U盘,并备份好U盘中的数据(操作过程会将U盘格式化,清空其中的数据) 在 arch 下载页面 下载 arch 的可引导 ISO 文件。 下载并安装 rufus ,按照提示将 arch 的可引导 IOS 文件刻录到 USB 安装媒介。  配置 live 环境 在计算机加电自检时快速按下某个热键,进入引导加载程序菜单,选择 Arch Linux install medium 进入安装环境,安装环境默认的 Shell 是 Zsh。  第一步是连接互联网,可以直接使用有线网络,连接网线之后会自动联网,也可以使用 iwctl...
