Skip to content

Instantly share code, notes, and snippets.

@KuRRe8
KuRRe8 / GIST.MD
Created April 28, 2025 21:55
I love GitHub Gist

⚡ I LOVE GIST ⚡

🎯 One file. One idea. One universe.

🚀 Why Gist is the Best Thing Ever

  • Zero setup, zero commitment.
    ✅ Code now, organize... maybe never.

  • Public? Private?

@KuRRe8
KuRRe8 / HomeDecoration.md
Last active April 30, 2025 13:20
useful settings reside in *nix $HOME

Home Decoration

Every user have their own $HOME.

The responsibility is to keep the $HOME neat and comfortable.

Many user scope configurations are stored under home root in some files or folders named with preceeding '.' .

Here are some practical settings. They are originally set up on supercomputers of NSCC, 2024.

@KuRRe8
KuRRe8 / PythonSnippets.md
Last active May 6, 2025 01:56
small repo for personal use, welcome to contribute

Python Snippets

Useful code for daily development.

宏定义的现代 C++ 替代方案对照表

在现代 C++(C++11 及以上)中,应尽量避免使用 #define 宏来定义常量、函数或逻辑片段,因为宏是预处理器层面的文本替换,不受类型系统、作用域规则约束,容易引发错误。以下是推荐的替代方案及理由。


宏与现代 C++ 替代对照

旧式宏用法 推荐替代 原因与说明
@KuRRe8
KuRRe8 / _cxx_snippets.md
Last active May 8, 2025 23:39
useful cpp snippets

C++ Snippets

For personal use

@KuRRe8
KuRRe8 / _autoplayconnect4.md
Last active May 3, 2025 23:12
autoplay connect4 in gameboardarena

Autoplay Connect 4

connect 4 is a well-known game which receives a lot of attention in the AI community. The game is played on a 7x6 board, where two players take turns dropping colored discs into columns. The objective is to connect four discs in a row, either horizontally, vertically, or diagonally.

How to compile and use

in wsl g++ -std=c++17 -O3 main.cc then in windows `

@KuRRe8
KuRRe8 / 0_Intro.md
Last active May 10, 2025 08:58
现代C++的一些新特性,以17、20、23版本为例

现代C++

C++ 11/14作为一个奠基版本,构造了近年来编写C++的新范式。

本人熟悉的主要语言技术栈有C/C++, Python, Matlab, C#, 相比之下,C++的变化是最频繁的,也是最有趣的

多数人已然熟悉C++11/14的用法,本Gist仓库旨在总结一些17及以后版本的特性。

欢迎在讨论区发表相应见解。

@KuRRe8
KuRRe8 / _intro.md
Last active May 9, 2025 02:06
和Python使用有关的一些教程,按类别分为不同文件

Python教程

Python是一个新手友好的语言,并且现在机器学习社区深度依赖于Python,C++, Cuda C, R等语言,使得Python的热度稳居第一。本Gist提供Python相关的一些教程,可以直接在Jupyter Notebook中运行。

  1. 语言级教程,一般不涉及初级主题;
  2. 标准库教程,最常见的标准库基本用法;
  3. 第三方库教程,主要是常见的库如numpy,pytorch诸如此类,只涉及基本用法,不考虑新特性

其他内容就不往这个Gist里放了,注意Gist依旧由git进行版本控制,所以可以git clone 到本地,或者直接Google Colab\ Kaggle打开相应的ipynb文件

@KuRRe8
KuRRe8 / 0_ros2.md
Last active May 10, 2025 22:47
ros2 通识

ROS2 教程

ROS是大家喜闻乐见的机器人操作系统,本Gist介绍一些基本用法

@KuRRe8
KuRRe8 / _.md
Created May 12, 2025 21:47
my scratch pad

Notebook Frontpage