Threads
- Threads are wrapper around OS Threads
- Have a cost and consume memory
- Can't have many, need a thread pool
- Good for CPU Bound, not good for IO Bound.
- 2k metadata, 1MB stack, 1-10us context switch
created: 01.FEB.2024
I love to learn new programing languages, it help to open the mind to new possibilities and compare different approaches. For instance, I learned Ruby and Scala in 2010, Clojure and Haskell in 2011, Go in 2015, Kotlin 2016, Rust in 2018 and Idris, TypeScript in 2019, 2020 Pandemic strike did a bunch of pocs but not with new langs(crazy year), Zig in 2021, 2022(coding in lots of langs but nothing new) - in 2023 I'm learning Nim and V. Learn at least one lang per year. This post is not complain, it's just to share some toughts, notes and impressions.
sed -n 's,.*<GetCompensableProductIdentification>\(.*\)</GetCompensableProductIdentification>.*,\1,p' input
problem:
cgroups: cannot found cgroup mount destination: unknown
fix:
sudo mkdir /sys/fs/cgroup/systemd
sudo mount -t cgroup -o none,name=systemd cgroup /sys/fs/cgroup/systemd
set nocompatible " be iMproved, required | |
filetype off " required | |
" | |
" Vim spesific editor configs | |
" | |
set encoding=utf-8 | |
set number " Show line numbers | |
set backspace=indent,eol,start " fix backspace | |
set mouse=a " fix mouse to it only scroll inside vim not outside |
Error:
nvm is not compatible with the npm config "prefix" option:
Fix: add this 2 lines in your profile. vim ~/.zshrc
npm config delete prefix
npm config set prefix $NVM_DIR/versions/node/v21.5.0
❯ pocs-count.sh | |
Java : 605 | |
Scala : 119 | |
Rust : 186 | |
Go : 106 | |
C : 18 | |
C++ : 55 | |
Kotlin : 50 | |
Clojure : 82 | |
Haskell : 21 |
~/.SpaceVim
git checkout v2.2.0
You can look your vim/nvim compatible version here: https://spacevim.org/
I had issues with spacevim 2.3.0-dev so I had to force v2.2.0
IF you want to know your vim version do:
❯ vim --version
bash <(curl -fsSL https://raw.githubusercontent.com/liuchengxu/space-vim/master/install.sh)
more one: https://github.com/liuchengxu/space-vim