This file contains 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
const fs = require('fs'); | |
const xaotas = fs.readFileSync('./xaotas.txt').toString().split('\n'); | |
const before = 'Сегодня ты'; | |
const after = 'xaota!'; | |
const middle = shuffle(xaotas).slice(0, random(4) + 1).join(' '); | |
const result = [before, middle, after].join(' '); | |
console.log(result); |
This file contains 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 rdmd | |
import std.stdio, std.string, std.json, std.array, std.conv; | |
import std.algorithm: each, map, sum, fold; | |
import std.algorithm.comparison: equal; | |
import std.array: join; | |
import std.exception: enforce; | |
void main() { | |
jsonTxt2csv("input.json.txt", "output.csv") |
This file contains 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/local/bin/node --max_old_space_size=1024 | |
"use strict"; | |
const fs = require('fs'); | |
/* eslint-disable */ | |
class StreamBuffer { | |
constructor() { | |
this.blocks = []; |