Skip to content

Instantly share code, notes, and snippets.

View divan's full-sized avatar

Ivan Danyliuk divan

View GitHub Profile
@jboner
jboner / latency.txt
Last active July 24, 2024 19:52
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
----------------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD
@dkormalev
dkormalev / gist:3748554
Created September 19, 2012 08:59
Qt Notes Podcast s02e01 конкурс
Необходимо создать (на чистом QML или на QML с использованием C++) менеджер экранов,
аналогичный используемому в Android, MeeGo, Symbian, etc.
Ключевым отличием является использование грида, а не одномерного списка экранов.
То есть, например, мы можем создать сетку экранов 3x3, по которой будет перемещаться пользователь
(вверх-вниз-влево-вправо). Именно вниз-вверх-влево-вправо, по диагонали не надо.
В окне приложения всегда виден один экран,
при драге мышкой из любой точки экрана в одну из сторон -
переключаемся на другой экран (если он есть в гриде экранов конечно).
@region23
region23 / golang_books_sites.md
Last active July 18, 2024 08:27
Полезные ресурсы для изучающих Go

На русском языке

Русскоязычные сайты и сообщества

English resources

Go vs. Scala (Akka) Concurrency

A comparison from 2 weeks using Go.

Actors vs. Functions

Akka's central principle is that there you have an ActorSystem which runs Actors. An Actor is defined as a class and it has a method to receive messages.

This document has moved!

It's now here, in The Programmer's Compendium. The content is the same as before, but being part of the compendium means that it's actively maintained.

@zsfelfoldi
zsfelfoldi / ulc.txt
Last active February 19, 2018 10:09
Here are some pointers to implementing the ULC mode. Just take a look at the relevant code, then feel free to ping me whenever you have questions (I guess it will happen a few times, I tried to document the most important parts but some of the code is still a bit messy, which I apologize for in advance).
- adding the ultra light client option:
Add an extra option for light client mode where the user can specify a text/json ULC config file that contains a list of trusted server enodes and N out of M parameters (which may depend on how many servers we are connected to, there may be 5 servers listed but we can still accept 2 out of 3 connected).
Geth parameters are implemented like this:
https://github.com/ethereum/go-ethereum/blob/master/cmd/utils/flags.go#L162
Search for LightModeFlag or LightServFlag to find out how it is wired through the code.
- requesting signed headers
@eanakashima
eanakashima / vizprog.md
Last active September 25, 2018 15:39
Whoa, Pictures! A Visual History of Visual Programming (2018): References
@mkevac
mkevac / gist:a4cb823a560c13c9bfe914c395666828
Created December 16, 2018 14:34
YouTube subscriptions
Science
----
15x4 Talks: https://www.youtube.com/channel/UCMAr-94KkdtiSqHoRJCPK1Q
3Blue1Brown: https://www.youtube.com/channel/UCYO_jab_esuFRV4b17AJtAw
minutephysics: https://www.youtube.com/channel/UCUHW94eEFW7hkUMVaZz4eDg
Real Engineering: https://www.youtube.com/channel/UCR1IuLEqb6UEA_zQ81kwXfg
SmarterEveryDay: https://www.youtube.com/channel/UC6107grRI4m0o2-emgoDnAA
Vihart: https://www.youtube.com/channel/UCOGeU-1Fig3rrDjhm9Zs_wg
Vsauce: https://www.youtube.com/channel/UC6nSFpj9HTCZ5t-N3Rm3-HA
@SkatingScores
SkatingScores / CoP_Critique_Sources.csv
Last active April 9, 2019 19:45
CoP/IJS Critique Sources
We can make this file beautiful and searchable if this error is corrected: It looks like row 6 should actually have 5 columns, instead of 4. in line 5.
Author,Date,Pub,Title,Link
Sandra Loosemoore,May 2003,Frogs On Ice,Code of Points Considered Harmful,http://www.frogsonice.com/skateweb/articles/code-of-points.shtml
Katherine Godfrey PhD,May 2003?,SkateFair.org,Statistical Consequences of the ISU's New Cumulative Scoring System,https://web.archive.org/web/20100131081126/http://www.skatefair.org/media/copanalysis.php
Eric Zitzewitz,06 Jan 2006,Journal of Economics and Management Strategy,Nationalism in Winter Sports Judgingand Its Lessons for OrganizationalDecision Making,https://onlinelibrary.wiley.com/doi/epdf/10.1111/j.1530-9134.2006.00092.x?referrer_access_token=Ivpkk0cEoXt8ZclKtWknKIta6bR2k8jH0KrdpFOxC65gKbkIAGZYRBVcC8hWgYQKvtKv8WnoGleJPgED3rAUMnMyjshQVd2xam8FrOsQxTpLXD9EiJnxir0SXcoZABBP3AZzyfsm3C69aVnQNClkfw%3D%3D
,16 Feb 2006,Seed Magazine,Finding Flaws in Figure Skating,https://web.archive.org/web/20120714095006/http://seedmagazine.com/content/article/finding_flaws_in_figure_skating/
John Emerson,Spring/Summer 2006?,Yale,The Computer: A Phantom Figure