Skip to content

Instantly share code, notes, and snippets.

View leejseo's full-sized avatar
🤔
:thinking_face:

Jongseo Lee leejseo

🤔
:thinking_face:
View GitHub Profile
@cgiosy
cgiosy / dlas.hpp
Last active January 21, 2025 04:49
Diversified Late Acceptance Search
#ifndef DLAS_HPP
#include "intdef.hpp"
#include <array>
#include <algorithm>
#include <functional>
#include <utility>
template<class T, class U>
T incMod(T x, U mod) {
@finalchild
finalchild / convex-hull.cpp
Last active January 29, 2021 07:11
convex-hull.cpp
#include <algorithm>
#include <concepts>
#include <iostream>
#include <ranges>
#include <type_traits>
#include <vector>
#define self (*this)
#define repeat(i, n) for (remove_cv_t<remove_reference_t<decltype(n)>> i = 0; i < (n); ++i)
using namespace std;
@Treeki
Treeki / TurnipPrices.cpp
Last active July 26, 2025 06:27
AC:NH turnip price calculator
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
// munged from https://github.com/simontime/Resead
namespace sead
{
class Random
{
@bgadrian
bgadrian / set.go
Last active May 28, 2025 02:02
How to implement a simple set data structure in golang
type Set struct {
list map[int]struct{} //empty structs occupy 0 memory
}
func (s *Set) Has(v int) bool {
_, ok := s.list[v]
return ok
}
@jnaecker
jnaecker / git+overleaf+github.md
Last active March 10, 2025 21:00
Using Overleaf as your TeX editor but getting your files to Github

git + overleaf + github

Setup

Connect Overleaf and your local repo

  1. Make a new project on Overleaf.
  2. In the share menu, copy the link from "Clone with git"
  3. On your computer:
    • use cd to navigate to where you want to put your project
@n3wtron
n3wtron / converter.go
Created June 28, 2017 09:50
golang: grpc Struct converter fom map and golang struct
package util
import (
protobuf_struct "github.com/golang/protobuf/ptypes/struct"
"errors"
"fmt"
"reflect"
"github.com/fatih/structs"
)
@tony612
tony612 / arcanist_cheatsheet.md
Last active July 7, 2023 05:29 — forked from sekimura/gist:6367366
arcanist cheatsheet
  • create tasks T{NNNN} asign them
  • create a branch with name like "T{NNNN}-boo-hoo"
  • git checkout -b T1234-boo-foo
  • commit changes on that branch until it gets ready to be reviewed
  • git commit -am 'first'
  • git commit -am 'now it works'
  • check if it's lint free (NOTE: it runs lint against only modified files)
  • arc lint
  • push a review request to the server. This will create a diff with id D{NNNN}
  • arc diff