Skip to content

Instantly share code, notes, and snippets.

@d0lfyn
d0lfyn / 20210103-computational-counterpoint-(original).rb
Last active November 9, 2023 09:16
'Computational Counterpoint' for Sonic Pi (dedicated to Steve Reich)
##| computational organisms (computational counterpoint, dedicated to Steve Reich)
##| v0.0.3 (20210103)
##| by d0lfyn (twitter: @0delphini)
##|
##| a development of "pattern-oriented" music, this program creates
##| worlds in which patterns live, evolve, and interweave
##|
##| history:
##| v0.0.1 (20210102)
##| + initial implementation
@d0lfyn
d0lfyn / 20210102-computational-organisms.rb
Last active November 9, 2023 09:16
Computational Organisms for Sonic Pi
##| computational organisms
##| environment
use_bpm 480;
# t = Time.new;
# use_random_seed ((t.to_i * 1000000000) + t.nsec);
use_random_seed Time.new.to_i;
# use_random_seed 0;
<!DOCTYPE html>
<html lang="en">
<body>
<button id="button">play greeting</button>
<script>
const greeting = () => {
window.speechSynthesis.onvoiceschanged = function () {
window.speechSynthesis.cancel();
window.speechSynthesis.getVoices();
@SahilFruitwala
SahilFruitwala / Data_Cleaning.py
Last active November 19, 2023 13:02
Data Cleaning Code
import pandas as pd
"""
Data Loading
"""
# df = pd.read_csv('my_file.csv')
# df = pd.read_csv('my_file.csv', delimiter=',')
# df = pd.read_csv('my_file.csv', delimiter=',', header=None)
df = pd.read_csv('my_file.csv', delimiter=',', header=0, names=['Id','Name', 'Type', 'Price'])
@digikar99
digikar99 / lisp-resources-digikar-2020.md
Last active January 29, 2025 06:24
If programming is more than just a means of getting things done for you, then Common Lisp is for you!
@vindarel
vindarel / Common Lisp VS Racket - testimonies.md
Last active June 19, 2026 21:31
Common Lisp VS Racket. Feedback from (common) lispers.

Developer experience, libraries, performance… (2021/11)

I'll preface this with three things. 1. I prefer schemes over Common Lisps, and I prefer Racket of the Schemes. 2. There is more to it than the points I raise here. 3. I assume you have no previous experience with Lisp, and don't have a preference for Schemes over Common Lisp. With all that out of the way... I would say Common Lisp/SBCL. Let me explain

  1. SBCL Is by far the most common of the CL implementations in 2021. It will be the easiest to find help for, easiest to find videos about, and many major open source CL projects are written using SBCL
  2. Download a binary directly from the website http://www.sbcl.org/platform-table.html (even for M1 macs) to get up and running (easy to get started)
  3. Great video for setting up Emacs + Slime + Quick Lisp https://www.youtube.com/watch?v=VnWVu8VVDbI

Now as to why Common Lisp over Scheme

@Mr4k
Mr4k / differentialdithering.ipynb
Created September 9, 2020 02:32
DifferentialDithering.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@tdcosta100
tdcosta100 / WSL2GUIXvnc-en.md
Last active May 29, 2026 02:51
A tutorial to use GUI in WSL2 replacing original XServer by Xvnc, allowing WSL to work like native Linux, including login screen

WSL2 with GUI using Xvnc

Note

If you want to use pure WSLg, you can try the new WSLg (XWayland) tutorial or the WSLg (Wayland) tutorial.

In this tutorial, we will setup GUI in WSL2, and access it using VNC. No additional software outside WSL (like VcXsrv) is required, except, of course, a VNC Viewer (RealVNC, TightVNC, TigerVNC, UVNC, etc, all of them might work flawlessly).

The key component we need to install is the desktop metapackage you want (GNOME, KDE, Xfce, Budgie, etc) and tigervnc-standalone-server.

For this setup, I will use Ubuntu (20.04, 22.04 and 24.04 are working), and install GNOME Desktop. Since the key components aren't bound to Ubuntu or GNOME, you can use your favorite distro and GUI. Check the [Sample

@onlurking
onlurking / programming-as-theory-building.md
Last active July 13, 2026 23:44
Programming as Theory Building - Peter Naur

Programming as Theory Building

Peter Naur

Peter Naur's classic 1985 essay "Programming as Theory Building" argues that a program is not its source code. A program is a shared mental construct (he uses the word theory) that lives in the minds of the people who work on it. If you lose the people, you lose the program. The code is merely a written representation of the program, and it's lossy, so you can't reconstruct

A Journey into Haskell and Open Source

I want to write something to celebrate the latest and I hope the last release of wstunnel, a TCP/UDP tunneling websocket tool, and share with you at the same time my story with Haskell and OpenSource projects.

A venture into Haskell

This open source project is not my only one, but is found to my hearth because it brought me joy, despair, proud, shame and further reach that I wasn't even expecting at first. If you have not noticed, the program is written in Haskell. I started learning it, well 8 years ago now..., when I was studying abroad in South Korea. At the time I was struggling with the feeling that I was not enough, I already knew C++ and Java, but was feeling like stagnating while there was so much more that I wasn't knowing. I wanted to be more and thus I needed to dedicate myself to learn more in order to be better. This fear of stagnation is still present in me even today, and if you are working as a programmer, I t