HNHacker News
TopNewBestAskShowJobs

anaphor

2,594 karma · joined August 15, 2013

You can email me at wes /AT/ wesk.tech
submissionscomments
anaphor··on My favorite prime number generator
There's a functional / lazy version I like that uses a priority queue in order to get the next prime number https://www.cs.hmc.edu/~oneill/papers/Sieve-JFP.pdf

It basically uses the priority queue to store all the composites up to a certain point and then you can assume the next one is prime.

I had some (admittedly not well written) code for it too https://gist.github.com/weskerfoot/4699275

It can also incorporates the wheel factorization optimization mentioned in this article.

anaphor··on Ask HN: Why do many CS graduates lack foundational knowledge?
Because they all cheated on their coursework and got graded on a curve for exams. Source: I was a TA for an intro CS course.
anaphor··on Ask HN: Can you recommend a book to learn basic electrical concepts/engineering?
Watch EEVblog's playlist on DC theory, and then play around with a breadboard and simulations using something like circuitjs. Get some basic tools such as a soldering iron (and solder/wick/sponge/etc), breadboard, wires, and a collection of components like resistors, capacitors, and LEDs, and so on. r/AskElectronics has a guide for all of the practical stuff you need. Pick a project you actually find interesting and work on it (after learning how to safely use your tools and components).

Lots of people get started with things like using a microcontroller to light up some LEDs and so on. That will introduce you to basic concepts like how transistors work as well if you dig into it.

https://www.youtube.com/watch?v=xSRe_4TQbuo&list=PLvOlSehNtu...

https://www.falstad.com/circuit/circuitjs.html

https://www.reddit.com/r/AskElectronics/wiki/beginners/

anaphor··on Rogers Canada, please fix the damn internet in Canada
I have Teksavvy via Cogeco and had no issues (obviously). I just discovered Rogers owns 41% of their shares though :|
anaphor··on Five major Canadian banks mysteriously go offline in hours-long outage
These are just reports people made that the sites were down. Not actual data from monitoring tools or something. I used my Canadian banking website a bunch of times yesterday and had no issues. Banking websites go down for maintenance or randomly start acting slow because of the crappy infrastructure they're built on, or because of other reasons located between your computer and their servers. Nothing I've seen shows any actual evidence that anything out of the ordinary happened. Just confirmation bias.
anaphor··on Living on 24 hours a day
Or block all of the non-educational youtube channels. Personally a good portion of my youtube usage is educational videos about electronics now. It feels like much less of a waste of time than twitter or instagram.
anaphor··on Memories of the “Sneakers” Shoot (2012)
They referenced the movie on Stranger Things as well with a line similar to the one River Phoenix's character says: "It's fascinating what 50 bucks will get you at the county recorder's office"
anaphor··on Why It’s So Difficult – and Costly – To Secure Chips
You can even place a backdoor on a circuit without any noticeable physical changes (other than chemical differences which are extremely hard to detect). You basically change which chemicals are used to "dope" the transistors, which changes their polarity.

See: https://news.ycombinator.com/item?id=26860715

anaphor··on Ask HN: Has Google search become quantitatively worse?
It works if you put it in "Verbatim" mode for that particular search, but I don't know how to make it permanent. Does anyone know if there's a way to always force it to use "verbatim" mode?
anaphor··on Nim Community Survey
That's awesome. I didn't file an issue yet but I was hoping to try it again soon and get a better idea of what's going wrong first.
anaphor··on Nim Community Survey
You can always call the C functions directly (from a shared lib) although admittedly it's a pain because you have to deal with unmanaged pointers very often.
anaphor··on Nim Community Survey
I would really like to see more work on improving the use of Nim for programming microcontrollers. I stumbled on to https://github.com/elcritch/nesper recently and it looks neat, but I had issues getting my code to compile. Improved support for other MCUs like the esp8266 and atmega32u4 would be really cool and useful. It would be nice to have Nim as a higher level alternative to micropython or lua in the embedded world (your only other real alternatives being C/C++ or Rust).

I also found this https://disconnected.systems/blog/nim-on-adruino

anaphor··on Doubling the PinePhone storage speed with a soldering iron
good to know! I was a bit confused by that at first :)
anaphor··on Doubling the PinePhone storage speed with a soldering iron
So this blog post covers the 1.0 hardware revision, but I just opened up mine out of curiosity and realized I have the 1.2 revision, which uses the sandisk chip, so everything is different. Not 100% sure which components need to be changed there, but it would be good to figure out the exact instructions for both types.
anaphor··on Doubling the PinePhone storage speed with a soldering iron
I would recommend getting a roll of kapton tape as well (make sure it's not counterfeit), and then use that to mask other components so you don't accidentally damage stuff
anaphor··on Doubling the PinePhone storage speed with a soldering iron
you could use an appropriate hot air station + some flux as well I think (and a good pair of tweezers designed for electronics)

Also, kapton tape is very useful if you're afraid of damaging stuff around it

anaphor··on ProctorU is dystopian spyware
Doctors google rare disease symptoms sometimes, however, and it's seen as a legitimate thing to try if you're truly stumped by a mysterious illness.
anaphor··on HTTP is obsolete – it's time for the distributed, permanent web (2015)
Named-data networking is literally what this is describing, except NDN works as a replacement for TCP, not HTTP. In the long term I'd rather have it work at a lower level and not have to think about it much. https://www.youtube.com/watch?v=gqGEMQveoqg
anaphor··on Multitasking Doesn't Work
And if you enjoy piano, there's some music specially created for this purpose https://en.wikipedia.org/wiki/Vexations
anaphor··on Multitasking Doesn't Work
I find that I can focus better if I listen to a single track on repeat (I've done it literally for hours). The repetition helps for some reason because you're not surprised.
anaphor··on Reasons to Quit Social Media
They're presenting a bit of a false dichotomy. You can use social media and still be sane, you just have to have some amount of self awareness so the troubling aspects don't affect you as much.
anaphor··on Show HN: Web browser to help programmers think clearly
I'm guessing this is done with WebKit so I wonder how hard it would be to port to Linux/Windows. Also it would be neat to have vim-like keyboard shortcuts.
anaphor··on Many young people diagnosed with Tourette’s after watching a YouTube channel
I'm assuming you've read the book and have looked at all of the arguments and evidence in it, otherwise this might seem like an uninformed opinion.
anaphor··on Many young people diagnosed with Tourette’s after watching a YouTube channel
One of the people quoted in this article, Robert E. Bartholomew, also wrote a book on the Havana Syndrome, which is most likely another case of mass psychogenic illness.

https://www.springer.com/gp/book/9783030407452

I've been reading it, and I would highly recommend it to anyone who wants to learn more.

anaphor··on Forgetting My First Language
Seems to be much more common as a thing with children who haven't finished acquiring both their L1 and L2 (as in multilingual) while still going through the biological sensitive period where you have to acquire language.

https://en.wikipedia.org/wiki/Language_attrition#Age_effect

anaphor··on So You Want to Study Philosophy
As someone with a philosophy degree this isn't a great list. Most of the recommended readings seem like random textbooks they found. It's pretty light on actual source material, and when they do list it, it's a bit bizarre, like recommending "On Formally Undecidable Propositions of Principia Mathematica and Related Systems" for philosophy of mathematics (Not that I think it's not worth reading, but not as your introduction to philos of math!), or recommending Kuhn as a supplemental reading, but not Popper, Bacon, Hume, etc.

FWIW, for philosophy of mathematics, I'd recommend reading "Introduction To Mathematical Philosophy" by Bertrand Russell. The recommendation of The Frege Reader is actually good, but I'd recommend watching some lectures or something as well, otherwise it'll be a difficult read.

anaphor··on A Lisp interpreter written in Lisp (2017)
Sort of

  $ cat lol.c 
  #include <stdio.h>
  #include </dev/tty>
  $ gcc lol.c
  int main() { printf("lol\n"); } // hit Ctrl+D
  $ ./a.out 
  lol
anaphor··on CIA director says he is escalating efforts to solve 'Havana Syndrome'
That is complete nonsense. The study you're quoting was discredited. They essentially grouped a bunch of random symptoms together and said they were the same thing. If you run enough tests for different things you'll eventually find something "wrong", that doesn't mean there actually is.
anaphor··on Do Low-Level Optimizations Matter? (2020)
This is a thing, see https://www.youtube.com/watch?v=FJJTYQYB1JQ (talk by Andrei Alexandrescu at CppCon 2019 about this exact idea)
anaphor··on Some stealth edits Vox made to its article debunking “conspiracy theories”
It exists for NYT headlines https://twitter.com/nyt_diff

Also https://twitter.com/newsdiffs

Page 1 of 26Next →