Going beyond Binary Conditions for CSS Calculations, Ana Tudor takes it to a whole new level by introducing the logical operations (and, or, nand, nor, not, and xor) to CSS — all built on top of calc() Very often, while using switch variables, I wish I could perform logical operations on them. We don’t have […]

# Tag Archives: math

## Logical Operations with

## How to Land the Space Shuttle … from Space

Highly entertaining and very informative talk by space/NASA-enthousiast Bret Copeland on how to land – the now defunct – Space Shuttle … from Space.

## WTFJS with Math (or why `0.1 + 0.2`

results in `0.30000000000000004`

)

A few fun little Math-related wtfjs examples. A classic one is adding an empty Array and an empty Object: [] + {} // ‘[object Object]’ {} + [] // 0 If you’re looking for a hint: Coercion. JS WTF with Math →0.30000000000000004.com →

## CSS attribute value less than / greater than / equals selectors

Yesterday Ana Tudor wondered if should could write CSS selectors using less-than and greater-than logic: CSS attribute selector wish:[data-code>2][data-code<19] { /* styles */ }[data-code>=19][data-code<65] { /* other styles */ }and so on… — Ana Tudor (@anatudor) October 12, 2016 Unfortunately this kind of selectors don’t work (yet). Until then one could use JavaScript to tackling […]

## Extracting Looping GIFs From Videos

Finding and extracting well-looping segments from a movie requires much attention and patience […] To make things easier I wrote a Python script which automates the task. This post explains the math behind the algorithm and provides a few examples of use. Fuck yeah, math! Or, as the author states: Yet another big problem of […]

## 248 days

Mattias, connecting the dots: For those of us that own a Boeing 787 Dreamliner, don't forget to reboot it every 248 days! https://t.co/N19S953XHQ — ma.ttias.be (@mattiasgeniar) May 2, 2015 Geekfun! 🙂 248 days →

## Cubic Bezier Curves – Under the Hood

Because, math!

## Dancing Math

## The Frequency of Humanity

Every day on Earth, an estimated 371,124 people are born and 154,995 people die. When you ask Wolfram Alpha about these rates, the scientifically inclined site returns a curious corresponding quantity: the frequency in hertz. If you subtract the death rate from the birth rate, you get a net rate of 216,129 new people a […]

## Threes

Threes is tiny puzzle that grows on you. Combine 1 and 2 to get a 3. From then on, combine two of the same numbers to get a new number until the grid is locked. Don’t let the simplicity of the game fool you: it took quite some time to create it. Threes (iTunes Store) […]