Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Istvan l1x

🏠
Working from home
View GitHub Profile
@kachayev
kachayev / concurrency-in-go.md
Last active Sep 25, 2020
Channels Are Not Enough or Why Pipelining Is Not That Easy
View concurrency-in-go.md
@ashrithr
ashrithr / kafka.md
Last active Aug 26, 2020
kafka introduction
View kafka.md

Introduction to Kafka

Kafka acts as a kind of write-ahead log (WAL) that records messages to a persistent store (disk) and allows subscribers to read and apply these changes to their own stores in a system appropriate time-frame.

Terminology:

  • Producers send messages to brokers
  • Consumers read messages from brokers
  • Messages are sent to a topic
@wch
wch / server.r
Last active Nov 13, 2019
Shiny example with stocks
View server.r
if (!require(quantmod)) {
stop("This app requires the quantmod package. To install it, run 'install.packages(\"quantmod\")'.\n")
}
# Download data for a stock if needed, and return the data
require_symbol <- function(symbol, envir = parent.frame()) {
if (is.null(envir[[symbol]])) {
envir[[symbol]] <- getSymbols(symbol, auto.assign = FALSE)
}
@louismullie
louismullie / pi-monte-carlo.py
Created Sep 23, 2012
Monte Carlo Estimation of PI in Python
View pi-monte-carlo.py
import random as r
import math as m
# Number of darts that land inside.
inside = 0
# Total number of darts to throw.
total = 1000
# Iterate for the number of darts.
for i in range(0, total):
You can’t perform that action at this time.