- Generate the file:
$ awk 'BEGIN { for(c=0;c<10000000;c++) printf "<p>LOL</p>" }' > 100M.html
$ (for I in `seq 1 100`; do cat 100M.html; done) | pv | gzip -9 > 10G.boomgz
- Check it is indeed good:
#set up the dir structure if it doesn't exist | |
set t ~/.trello; mkdir -p $t | |
function if_exist # we don't want to litter our code with ifs if a read model or events are not there yet. Return /dev/nul for empty | |
if test -e $t/$argv[1]; echo $t/$argv[1]; else; echo /dev/null; end | |
end | |
function list # provide lists from our tab delimited entries with filtering and line item numbers to make choices | |
set list $argv[1]; set column_to_show $argv[2]; set filter $argv[3]; set count 1 | |
cat (if_exist $list) | grep -e "$filter\$" | while read line | |
set -l line_items (string split \t $line) | |
echo $count\) $line_items[$column_to_show] |
Disclaimer: This piece is written anonymously. The names of a few particular companies are mentioned, but as common examples only.
This is a short write-up on things that I wish I'd known and considered before joining a private company (aka startup, aka unicorn in some cases). I'm not trying to make the case that you should never join a private company, but the power imbalance between founder and employee is extreme, and that potential candidates would
Kris Nuttycombe asks:
I genuinely wish I understood the appeal of unityped languages better. Can someone who really knows both well-typed and unityped explain?
I think the terms well-typed and unityped are a bit of question-begging here (you might as well say good-typed versus bad-typed), so instead I will say statically-typed and dynamically-typed.
I'm going to approach this article using Scala to stand-in for static typing and Python for dynamic typing. I feel like I am credibly proficient both languages: I don't currently write a lot of Python, but I still have affection for the language, and have probably written hundreds of thousands of lines of Python code over the years.
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv='Content-type' content='text/html; charset=utf-8'> | |
<title>Basic Example with JSX</title> | |
<link rel="stylesheet" href="base.css" /> | |
</head> | |
<body> | |
<h1>ReactJs + RxJs</h1> | |
<div id="container"> |
This is a study of interpersonal closeness, and your task, which we think will be quite enjoyable, is simply to get close to your partner. We believe that the best way for you to get close to your partner is for you to share with them and for them to share with you. Of course, when we advise you about getting close to your partner, we are giving advice regarding your behavior in this demonstration only, we are not advising you about your behavior outside of this demonstration.
In order to help you get close we've arranged for the two of you to engage in a kind of sharing game. You're sharing time will be for about one hour, after which time we ask you to fill out a questionnaire concerning your experience of getting close to your partner.
You have been given three sets of slips. Each slip has a question or a task written on it. As soon as you both finish reading these instructions, you should
<?php | |
use React\SocketClient\Connector; | |
use React\SocketClient\SecureConnector; | |
use React\Socket\Server; | |
use React\Stream\Stream; | |
require __DIR__ . '/../vendor/autoload.php'; | |
$loop = React\EventLoop\Factory::create(); |
<?php | |
require __DIR__ . '/../vendor/autoload.php'; | |
/** @var $loop \React\EventLoop\ExtEventLoop */ | |
$cfg = new \EventConfig(); | |
$cfg->requireFeatures(\EventConfig::FEATURE_FDS); | |
$loop = new \React\EventLoop\ExtEventLoop($cfg); | |
$dir = getcwd(); | |
$fd = fopen($dir . DIRECTORY_SEPARATOR . 'largefile', "r"); |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.