Skip to content

Instantly share code, notes, and snippets.

Avatar

Chien-Chih Wang jk13o3lll

View GitHub Profile
View A hack for showing LaTeX formulas in GitHub markdown.md

Problem

A lot of GitHub projects need to have pretty math formulas in READMEs, wikis or other markdown pages. The desired approach would be to just write inline LaTeX-style formulas like this:

$e^{i \pi} = -1$

Unfortunately, GitHub does not support inline formulas. The issue is tracked here.

Investigation

@jk13o3lll
jk13o3lll / uva_102.cpp
Created Dec 13, 2019
[UVa] 102 - Ecological Bin Packing
View uva_102.cpp
#include <stdio.h>
#include <stdint.h>
#include <inttypes.h>
#include <string.h>
int main(){
uint64_t b[3], g[3], c[3], total, tmp, min_move;
char sol[4];
while(scanf("%" SCNu64 "%" SCNu64 "%" SCNu64 "%" SCNu64 "%" SCNu64 "%" SCNu64 "%" SCNu64 "%" SCNu64 "%" SCNu64 ,
@jk13o3lll
jk13o3lll / uva_101.cpp
Created Nov 13, 2019
[UVa] 101 - The Blocks Problem
View uva_101.cpp
#include <stdio.h>
#include <string.h>
#include <stack>
using std::stack;
#define N 25
int pos[N];
stack<int> pile[N];
@jk13o3lll
jk13o3lll / uva_100.cpp
Last active Dec 13, 2019
[UVa] 100  - The 3n + 1 problem
View uva_100.cpp
// idea: make table, record value have been computed
#include <stdio.h>
#include <string.h>
#define N 1000001
int cycle_length[N];
int get_cycle_length(int i){
You can’t perform that action at this time.