Skip to content

Instantly share code, notes, and snippets.

View Lmanangka's full-sized avatar
👽
Upgrade

Leo Manangka Lmanangka

👽
Upgrade
View GitHub Profile
@Prakasaka
Prakasaka / bash-colors.md
Created July 25, 2020 09:14 — forked from JBlond/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
@taiar
taiar / integral.c
Created September 4, 2014 04:21
Integral with trapezium
#include <stdio.h>
#include <math.h>
double integral(double(*function)(double), double a, double b) {
double start = a;
double adder = 0.0001;
double end = a + adder;
double val = 0;
while(end < b) {
val += (((*function)(end)+(*function)(start))*(end-start))/2;