Coding without coding

Tools that will improve your code so you don't have to

  • iwyu: tidy includes to improve build times
  • clang-format: format your code
  • clang tidy

See also (Jason Turner)

  • reddit/r/cpp
  • C++ ISO home
  • (c++ section)
  • – compiler’s view of code
  • – search c++ standard
  • – up to the minute standard for the C++ programming language
  • (also includes a C reference and offline archive)


  • Fluent C++ (blog) – include daily tutorial for teams
  • C++ stories
  • Sutter’s Mill
  • Random ASCII by Bruce Dawson
  • Modernes C++
  • The Old New Thing (Raymond Chen)


  • Jason Turner
  • The Cherno
  • cppcon
  • bisqwit
  • OneLoneCoder
  • Meeting Cpp (conference channel)


Crib sheet

Fundamentals Terminology Identity matrix A Pixel Is Not A Little Square OpenGL Shading Language – GLSL Excerpts from Wikipedia. Variable types C has a number of basic types. GLSL uses some of these, but adds many more. Type qualifiers GLSL’s uses a large number of qualifiers to specify where the values that various variables contain come from. Qualifiers also modify how those variables can be used. [Read More]

Raspberry e*pi*phany

First experience of Raspberry Pi 4, Zero and Pico

Always be careful when running scripts and commands copied from the Internet. Anyway, that said… Getting start Download Raspberry Pi imager from the Play Store to write images to an SD card from your phone. You can use a wall charger but they run happily off a large powerbank if you wanna dev from the sofa. Connection differences between the Pi 4 and Zero type 4 Zero HDMI Micro Mini Power USB-C Micro-USB Operating systems It’s by far easiest to install Raspbian 32-bit. [Read More]

The Rules of Code

What lies beneath

A single file should contain fewer than 20000 lines of code. Preferably 1000. A single file should contain only one class. If this breaks the previous rule then your class is probably too large: refactor. It would be nice if a single routine could fit into 100 lines of code. Use consistent formatting. Even better: don’t bother and let clang-format do it. When you change your mind, just update the config and rerun over the codebase. [Read More]


Most recent development is managed in GitLab. I started in GitHub using Travis CI but I jumped ship when I discoverd the bright lights and built-in CI of GitLab. See my Wikipedia contributions and techie tidbits (plus cat pics) on Twitter. tracehost Network mapper using bash and GraphViz – repo/website Have A Nice Day Trader Trading strategy backtester – repo/website tradeR Currency analysis in R – repo/website BIGO Exploring Big ‘O’ programatically – website [Read More]


Ways to get

Via the (Linux) filesystem int r; std::ifstream("/dev/urandom").read(reinterpret_cast<char*>(&r), sizeof r); char r; std::ifstream{"/dev/urandom"} >> r; STL Uniform random bit generators uniform_random_bit_generator Engines and engine adaptors linear_congruential_engine mersenne_twister_engine subtract_with_carry_engine discard_block_engine independent_bits_engine shuffle_order_engine Non-deterministic generator random_device Distributions Uniform distributions uniform_int_distribution uniform_real_distribution generate_canonical Bernoulli distributions bernoulli_distribution binomial_distribution negative_binomial_distribution geometric_distribution Poisson distributions poisson_distribution exponential_distribution gamma_distribution weibull_distribution extreme_value_distribution Normal distributions normal_distribution lognormal_distribution chi_squared_distribution cauchy_distribution fisher_f_distribution student_t_distribution Sampling distributions discrete_distribution piecewise_constant_distribution piecewise_linear_distribution References https://en. [Read More]

Website hosting

On the cheap...

Hugo So this whole site is generated from markdown using the Hugo blog engine. And it’s hosted on GitLab completely free. See how I did it. This does really need settiing up from a softie, but once it’s in place you an edit and add articles within in the browser. 000webhost / Hostinger Free hosting is available from 000webhost – albeit with an advert. But you can go pro for as little as $2 a month. [Read More]


Challenger banks are small, recently created retail banks that compete directly with the longer-established banks in the country, sometimes by specialising in areas underserved by the “big four” banks (Barclays, HSBC, Lloyds Banking Group, and NatWest Group). See challenger bank on Wikipedia. Challenger banks Aldermore Atom Bank Metro Bank Monzo N26 OakNorth Shawbrook Bank Starling Bank Tandem Bank Investment banks lloydsbanking. [Read More]