7 Matching Annotations
  1. Last 7 days
  2. Jan 2022
    1. today is a day for best effort and gentle improvement. writing a self-review for work always makes me want to unalive myself (even when I think I'm doing well???) so we're not being real ambitious outside of getting that done (well, besides all the normal work nonsense).

      Same here :) I should really start writing perf before end of the month... I procrastinate a lot on it usually, even when I know it's silly.

  3. Apr 2021
    1. Holy xxx, it takes 3.37s to calculate merely 1,000,000 reciprocal numbers. The same logic in C takes just a blink: 9ms; C# takes 19ms; Nodejs takes 26ms; Java takes 5ms! and Python takes self-doubting 3.37 SECONDS.

      But numpy takes just 2ms!

  4. Mar 2020
  5. Sep 2018
    1. var el; var i = 0; var fragment = document.createDocumentFragment(); while (i < 200) { el = document.createElement('li'); el.innerText = 'This is my list item number ' + i; fragment.appendChild(el); i++; } div.appendChild(fragment);
    1. The fastest (): while (node.lastChild) { node.removeChild(node.lastChild); } Alternatives (slower): while (node.firstChild) { node.removeChild(node.firstChild); } while (node.hasChildNodes()) { node.removeChild(node.lastChild); }
  6. Apr 2018