This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| vim.keymap.set("n", "<C-g>", function() | |
| local hl_keywords = { | |
| ["class"] = true, | |
| ["function"] = true, | |
| ["namespace"] = true, | |
| ["method"] = true, | |
| ["type"] = true, | |
| ["enum"] = true, | |
| ["field"] = true, | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| local function binary_search(tbl, line) | |
| local left = 1 | |
| local right = #tbl | |
| local mid = 0 | |
| while true do | |
| mid = bit.rshift(left + right, 1) | |
| if not tbl[mid] then | |
| return | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| Xephyr -fullscreen -noreset :1 & | |
| sleep 1 | |
| export DISPLAY=:1 | |
| # set dpi | |
| xrdb -merge ~/.Xresources | |
| exec dwm 2>/dev/null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| local Job = require("plenary.job") | |
| local json = vim.fn.json_encode | |
| local function add(a, b) | |
| print("a + b = ", a + b) | |
| return a + b | |
| end | |
| local function Multiplication(a, b) | |
| print("a * b = ", a * b) | |
| return a * b |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CPP = g++ | |
| INCS = -I$(ZK_DIR)/src/c/include -I$(ZK_DIR)/src/c/generated | |
| LIBS = -L$(ZK_DIR)/src/c/.libs -lzookeeper_mt -lpthread | |
| CXX_FLAGS = -std=c++11 | |
| all: barrier | |
| barrier: ZkBarrierTest.o | |
| $(CPP) -o barrier ZkBarrierTest.o $(LIBS) |