This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env tclsh | |
# !! DEPRECATED !! THE NEWS ENDPOINT USED BY THIS SCRIPT HAS BEEN CLOSED !! | |
# Keep up with breaking news about Ukraine on the command line | |
# This Tcl script reports summaries of the most important events that | |
# took place since you last checked, scraped right from novinky.cz | |
# Dependencies: Tcl, curl | |
# Run with --raw, -r for a more parser-friendly format | |
# Run with --all, -a to list all the available news |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Jakub Sebek, Feb 2022, Public Domain | |
// Please report bugs | |
#include <stdio.h> | |
#include <stdbool.h> | |
#include <assert.h> | |
int main() { | |
bool stresc = false, rawstring = false, multil = false; | |
char strend = false, rawend[16+2] = ")", *rawdc = NULL; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
14. 6. 2021 | |
This piece of C99 code is a set of rudimentary functions for manipulating | |
linear functions of an aribtrary number of coefficients. This includes | |
a function for solving systems of an arbitrary amount of equations using | |
the substitution method. | |
Note that I aimed for the absolute best elegance of the code rather | |
than performance, which would require additional "if" checks, function |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <SDL.h> // The SDL library | |
#include <math.h> // sin, fmod | |
#include <stdio.h> // printf | |
#define BUFFER_DURATION 1 // Length of the buffer in seconds | |
#define FREQUENCY 48000 // Samples per second | |
#define BUFFER_LEN (BUFFER_DURATION*FREQUENCY) // Samples in the buffer | |
void play_buffer(void*, unsigned char*, int); |