Skip to content

Instantly share code, notes, and snippets.

@jakoss
jakoss / main.cs
Created July 15, 2020 12:59
Automated todoist tasks creation
void Main()
{
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Bearer <integration_token_here>");
var dates = new List<DateTime>();
for (int year = 2020; year <= 2023; year++)
{
for (int i = 1; i <= 12; i++)
{
@jakoss
jakoss / MediaDecoder.java
Created April 15, 2020 18:57 — forked from a-m-s/MediaDecoder.java
Android code to extract raw audio from arbitrary media files.
/* MediaDecoder
Author: Andrew Stubbs (based on some examples from the docs)
This class opens a file, reads the first audio channel it finds, and returns raw audio data.
Usage:
MediaDecoder decoder = new MediaDecoder("myfile.m4a");
short[] data;
while ((data = decoder.readShortData()) != null) {
@jakoss
jakoss / MediaDecoder.java
Created April 15, 2020 18:57 — forked from a-m-s/MediaDecoder.java
Android code to extract raw audio from arbitrary media files.
/* MediaDecoder
Author: Andrew Stubbs (based on some examples from the docs)
This class opens a file, reads the first audio channel it finds, and returns raw audio data.
Usage:
MediaDecoder decoder = new MediaDecoder("myfile.m4a");
short[] data;
while ((data = decoder.readShortData()) != null) {
#LINQPad optimize+
void Main()
{
BenchmarkRunner.Run<AnagramsBenchmark>();
}
[MemoryDiagnoser]
public class AnagramsBenchmark
{
interface IStickyHeader
@jakoss
jakoss / spinner_charset_iterate.go
Created August 7, 2015 20:45
Iterate through the all charsets in briandowns/spinner
package main
import (
"bufio"
"fmt"
"os"
"time"
"github.com/briandowns/spinner"
)
#include <iostream>
using namespace std;
void sumakontrolna(char * pakiet, long& suma, int n = 5){
for(int i = 0; i < n; i++)
suma += pakiet[i];
}
void sumakontrolna(int liczba, long& suma){