Programming Leftovers
-
Programming/Development
-
MaskRay ☛ C++ exit-time destructors
In ISO C++ standards, [basic.start.term] specifies that: [...]
-
Rlang ☛ Is rowSums slow?
I guess it might have been obvious, but I was surprised that rowSums appeared much slower slower than directly doing the matrix operation. At first I assumed it was because it has some overhead in the form of input handling/casting and other odds and ends.
-
Chen HuiJing ☛ Generating a weekly calendar from JSON data
The original purpose of this blog was for me to document solutions that I spent hours figuring out at work, which means it’s not my code therefore I cannot take it wholesale with me. I just extract the key parts, remove any references (or try to) to the original project and hopefully the next time I run into the problem, I have a solution.
Over the years, it has expanded to include code which had to be thrown away due to deprecated features, but the code is still good. Especially if I had called in favours with a smart friend to pair program the solution. You know who you are, Yishu.
-
Nicolas Fränkel ☛ The pitfall of implicit returns
Before diving into implicit returns, we must explain two programming concepts influencing them. A lot of literature is available on the subject, so I’ll paraphrase one of the existing definitions:
"An expression usually refers to a piece of code that can be evaluated to a value. In most programming languages, there are typically three different types of expressions: arithmetic, character, and logical."
"A statement refers to a piece of code that executes a specific instruction or tells the computer to complete a task."
-
Ignacio Brasca ☛ A Javascript Nightmare | Happiness Machines
JavaScript sometimes feels too malleable, too easy, too clean, but it’s not. The paybacks come later in the game.
Now our strategy will surely be to use at least a typed system or a more robust runtime. This mess cannot be there any longer, and if it is, JavaScript won’t be the tool to support it (since it’s strictly a bad tool).
-
Linux Hint ☛ 30 Examples of the C++ Vectors
Practical guide on the possible examples that are used in real-time applications related to vectors in the C++ programming language with syntax and parameters.
-
Brendan Gregg ☛ Brendan Gregg: The Return of the Frame Pointers
Sometimes debuggers and profilers are obivously broken, sometimes it's subtle and hard to spot. From my flame graphs page:
[...](Click for original SVG.) This is pretty common and usually goes unnoticed as the flame graph looks ok at first glance. But there are 15% of samples on the left, above "[unknown]", that are in the wrong place and missing frames. The problem is that this system has a default libc that has been compiled without frame pointers, so any stack walking stops at the libc layer, producing a partial stack that's missing the application frames. These partial stacks get grouped together on the left.
-
Perl / Raku
-
Perl ☛ 2024-03-09 [Older] Reading sequences from FASTA format alignment by Bio::Perl
-
J Wolfgang Goerlich ☛ We were wizards - a foreword to Learning Perls
We were wizards — a foreword to Learning Perl
In the 1990s, computers were magic and we were wizards. Want proof? I offer below, Larry Wall’s foreword to Learning Perl from 1993. It greatly inspired a very young me who wandered into a book shop, picked up an odd book with llama on the cover and a seemingly misspelled title. The first few pages had me hooked and led me on a romp that would last decades. I hope it’ll inspire you, too. As Larry put it, “So be it! So do it!” — Wolf
-
-
Python
-
The New Stack ☛ Python: The Many Ways to Merge a Dictionary
As you continue on your journey of learning Python, you’ll start working with larger data sets.
-
-
SQL
-
Linux Hint ☛ SQL Subtract
Practical guide on how to use the SQL Subtract feature and how it can help us when working with relational databases using the NOT IN operator using examples.
-
Linux Hint ☛ SQL Select All Except
Practical tutorial on all the methods to select all rows and columns from a given database table except the specific ones by utilizing various SQL techniques.
-
Linux Hint ☛ SQL Outer Join
Practical guide on understanding OUTER JOINS, what an OUTER JOIN is in SQL, the types of OUTER JOINS, and the examples of how to use these types of OUTER JOINS.
-
Linux Hint ☛ Case Insensitive SQL LIKE Operator
Practical guide on how to use the LIKE operator in Standard SQL you to check if a value is in a given set of values and perform a case insensitive comparison.
-
Linux Hint ☛ SQL Lead Function
Comprehensive tutorial on how to work with the lead() function to access the next item/row from the current row at a specific offset along with examples.
-
Linux Hint ☛ SQL Lag
Comprehensive guide on how to work with the SQL lag() function to get or access the previous item from the current row at a specific offset along with examples.
-
-
-
Standards/Consortia
-
Maarten ☛ [RSS] Feeds Display – a blogroll plugin for WordPress – filmvanalledag
RSS Feeds Display is a WordPress plugin that displays links to the latest articles from multiple RSS feeds in a chronological order (newest first). The RSS feeds are read from an OPML-file. It creates a dynamic blogroll.
-
New York Times ☛ Landline Users Remain Proudly ‘Old-Fashioned’ in the Digital Age
When millions of AT&T customers across the country briefly lost their cellphone service last month, Francella Jackson, 61, of Fairview Heights, Ill., said she picked up her well-worn Southwestern Bell push-button landline phone and called her friends “just so we could laugh at the people who could not use their phones.”
-