Skip to content

Instantly share code, notes, and snippets.

View gabryon99's full-sized avatar

Gabriele Pappalardo gabryon99

View GitHub Profile
@gabryon99
gabryon99 / notes.md
Last active May 31, 2023 07:45
Useful Research notes

Doing Literature Review

A literature review is a piece of academic writing demonstrating knowledge and understanding of the academic literature on a specific topic placed in context. A literature review also includes a critical evaluation of the material; this is why it is called a literature review rather than a literature report. It is a process of reviewing the literature, as well as a form of writing. (Definition from The University of Edinburgh

Useful videos:

@gabryon99
gabryon99 / generator.c
Created January 28, 2023 11:21
Implement simple JavaScript's generator in C
#include <stdio.h>
#include <stdlib.h>
#include <setjmp.h>
#define STACK_SIZE (4 * 1024) // 4KB
#define GEN_YIELD (1)
#define GEN_EXIT (-1)
#define yield(x) \
do { \
@gabryon99
gabryon99 / wheel.py
Created March 17, 2022 07:44
Wheel of Fortune!
#!/usr/bin/python3
import curses
import time
import random
def read_names():
return ["Foo", "Bar", "Baz", "FooBaz"]
@gabryon99
gabryon99 / timeoutFetch.js
Created November 12, 2020 09:34
Timeout Fetch
class RequestTimeoutError extends Error {
constructor(message) {
super(message);
this.name = "RequestTimeout";
}
}
const timeoutFetch = async (url, params = {}, timeout = 0) => {
// create a new abort controller to handle timeout
@gabryon99
gabryon99 / ntop-command-fedora31.txt
Created November 27, 2019 18:03
ntop installation on fedora 31
fedora dependencies:
+ libcap, libcap-devel: https://apps.fedoraproject.org/packages/libcap-ng-devel
+ openssl-devel, openssl: https://apps.fedoraproject.org/packages/openssl-devel
+ libcurl-devel: https://apps.fedoraproject.org/packages/libcurl-devel
+ libmaxminddb-devel: https://apps.fedoraproject.org/packages/libmaxminddb-devel
+ sqlite-devel: https://apps.fedoraproject.org/packages/sqlite-devel
- mysql-devel: not found, use mariadb instead
+ mariadb-devel: https://apps.fedoraproject.org/packages/mariadb-devel
+ radcli-devel: https://apps.fedoraproject.org/packages/radcli-devel
+ librdkafka-devel: https://apps.fedoraproject.org/packages/librdkafka-devel
@gabryon99
gabryon99 / jupyter-ocaml.md
Created November 24, 2019 19:35
How to install ocaml-jupyter module in Fedora

This guide is aimed for the people who receive from opam the following message:

~ opam install jupyter
> Sorry, no solution found: there seems to be a problem with your request.

No solution found, exiting...

I solved the problem, in Fedora, executing this commands (uninstalling OCaml, Opam and the other stuff related to):

# Install dependecies