Enable TCP BBR on Ubuntu server

Code Snippet / Linux Notes

2019.12.19

Enable TCP BBR on Ubuntu server

TCP BBR is a TCP congestion control algorithm developed by Google. It tackles shortcomings of traditional TCP congestion control algorithms (Reno or CUBIC). According to Google, it can achieve orders of magnitude higher bandwidth and lower latency.

Reverse array elements in C

Code Snippet / C Notes

2019.11.11

Reverse array elements in C

Reverse the elements of an array by swapping elements from opposite ends of the array.

Get Random Number Using Liquid

Code Snippet / Tutorials

2019.11.01

Get Random Number Using Liquid

Generate random numbers in Liquid was once possible with built-in rand(), but it has been taken out because it's easy to replicate in JavaScript and doesn't benefits to server side caching. However, you can actually get a random number in Liquid through a simple trick: making use of both the date & modulo Liquid filters.