News for hackers. Stuff that matters.
Re:Poll: Where do you live? by 101008 on Friday February 04, 2022 @02:44PM (#30211916)
I hope there is someone who knows how to code in this community to parse the results and do a nice visualization. I have a cousin who knows about computers, if noone knows here how to do it, I can ask him to try. He always helps me with my printer.
Re:Poll: Where do you live? by Zenbit_UX on Friday February 04, 2022 @04:31PM (#30213556)
I'm currently working on a vue + vuex server side rendered PWA with client side hydration.i found the perfect UI component library which only adds ~3mb of overhead,which went paired with Chart.js and of course wrapped with VueCharts.js should be able to query a graphql endpoint to process the results and display in the browser. What do you all think of kubernetes, overkill?
Re:Poll: Where do you live? by aerovistae on Friday February 04, 2022 @04:40PM (#30213681)
I thought it was serious until I got to the 3mb part, that was where the tone became clear.

It's funny because I found the first sentence so upsetting. "With client-side hydration" -- I was just thinking to myself god these stupid buzzwords, what does that even mean, just another recycled concept with a new web 3.0 name.

Re:Poll: Where do you live? by eyelidlessness on Friday February 04, 2022 @09:07PM (#30216327)
Client-side hydration has been a term of art since component-based web apps have been built with the same code on the server and client. It’s not some new buzzword. It’s an exceedingly common term and has been a major focus in the space for years.

But loljs or whatever plays well so go for it.

Re:Poll: Where do you live? by e12e on Friday February 04, 2022 @08:30PM (#30216097)
Client side hydration might be the waterboarding of data visualization.
Re:Poll: Where do you live? by whalesalad on Friday February 04, 2022 @07:23PM (#30215556)
have you considered the blockchain? and/or at least consider adding a language that is not Java, but runs on the JVM.
Re:Poll: Where do you live? by elpakal on Friday February 04, 2022 @07:27PM (#30215603)
I don’t know I feel like gRPC did you know it’s used at Google?
Re:Poll: Where do you live? by igetspam on Friday February 04, 2022 @09:30PM (#30216470)
This comment should come with a trigger warning.
Re:Poll: Where do you live? by Aeolun on Friday February 04, 2022 @07:27PM (#30215599)
I hear JavaScript is the new hotness.
Re:Poll: Where do you live? by riidom on Friday February 04, 2022 @05:17PM (#30214131)
I prefer the printed version from parent poster, thanks
Re:Poll: Where do you live? by ProZsolt on Friday February 04, 2022 @06:06PM (#30214753)
Kubrernetes is an old thechnology. It should be serverless!
Re:Poll: Where do you live? by jcun4128 on Friday February 04, 2022 @06:53PM (#30215259)
Add haproxy on it
Re:Poll: Where do you live? by TranquilMarmot on Friday February 04, 2022 @07:01PM (#30215325)
Don't forget to put it behind Cloudflare, too, wouldn't want it to go down from too much traffic
Re:Poll: Where do you live? by rubabredwan on Friday February 04, 2022 @04:42PM (#30213701)
https://wheredohnuserslive.vercel.app/

Visualized it by countries and us states. Should update every 30 seconds.

Re:Poll: Where do you live? by mordae on Friday February 04, 2022 @06:49PM (#30215197)
Please fix Czechia vs. Czech Republic mismatch. And Macedonia vs. North Macedonia.

Also, per-capita hacker density would be cool as well.

Re:Poll: Where do you live? by binarynate on Friday February 04, 2022 @06:02PM (#30214710)
That's awesome! Thank you for making this map.
Re:Poll: Where do you live? by Yajirobe on Friday February 04, 2022 @05:11PM (#30214053)
The US map is bigger than the rest of the world
Re:Poll: Where do you live? by tempestn on Friday February 04, 2022 @07:30PM (#30215634)
Should make this a top level comment so it can get voted to the top.

Edit: appears you did already!

Re:Poll: Where do you live? by cheeaun on Friday February 04, 2022 @08:55PM (#30216260)
Singapore is missing :(
Re:Poll: Where do you live? by l0b0 on Friday February 04, 2022 @02:57PM (#30212124)
Ask codegolf.stackexchange.com, there's probably a Mathematica one-liner to display a globe with colour-coded areas.
Re:Poll: Where do you live? by abdusco on Friday February 04, 2022 @04:29PM (#30213532)
I never understood the purpose of languages with unicode operators that can supposedly express a 30 line script in like 2 symbols.

Are they purpose built on the spot for CodeGolf?

Re:Poll: Where do you live? by lgeorget on Friday February 04, 2022 @04:44PM (#30213735)
Not on the spot, a condition for the answer to be accepted is that the language must exist before the challenge, but yes, many languages exist only just for the purpose of golfing. Mathematica is a legitimate language though, it just is the case that some operations are surprisingly compact.
Re:Poll: Where do you live? by LeifCarrotson on Friday February 04, 2022 @05:12PM (#30214063)
Like checking if an image is of a goat:

    ImageInstanceQ[x,"caprine animal",RecognitionThreshold->i/100]
https://codegolf.stackexchange.com/a/71680
Re:Poll: Where do you live? by danuker on Friday February 04, 2022 @04:47PM (#30213773)
I doubt Mathematica is built for code golf. Check out Burlesque (which is ASCII).

https://mroman.ch/burlesque/docs/BLSQ.html

Re:Poll: Where do you live? by e12e on Friday February 04, 2022 @08:36PM (#30216134)
If ask for a "histogram" of the data, did I just write a 30 line script as a single word?
Re:Poll: Where do you live? by airstrike on Friday February 04, 2022 @06:00PM (#30214688)
Someone should actually post it there and then post the question here...
Re:Poll: Where do you live? by emacs28 on Friday February 04, 2022 @02:58PM (#30212138)
I think I can help, I've been learning how to make bar graphs from tables in microsoft word
Re:Poll: Where do you live? by binarynate on Friday February 04, 2022 @05:16PM (#30214117)
Good idea! I created this page that shows a table with the current results:

https://nate.org/hacker-news-location-poll

Re:Poll: Where do you live? by stronglikedan on Friday February 04, 2022 @02:47PM (#30211963)
I'll try to whip up an Excel macro over the weekend, but I can't promise anything.
Re:Poll: Where do you live? by ShakataGaNai on Friday February 04, 2022 @02:52PM (#30212039)
Excel Macro's... What does a virus have to do with visualizations?! /s
Re:Poll: Where do you live? by cerved on Friday February 04, 2022 @03:06PM (#30212254)
It IS only VIRAL if you make it from clicks on the emails!!

ALWAYS make clicks with the RIGHT to be SAFE from VIRALS

Re:Poll: Where do you live? by jarrenae on Friday February 04, 2022 @05:37PM (#30214389)
I got you. Where does hacker news live? visualized: https://ae.studio/random/where-does-hacker-news-live
Re:Poll: Where do you live? by radiator on Friday February 04, 2022 @07:22PM (#30215552)
Thank you but unfortunately only the large discs are readable. I think a sorted datatable might serve the purpose better.
Re:Poll: Where do you live? by zhoujianfu on Friday February 04, 2022 @05:45PM (#30214495)
Nice!

A lot of Germans!

Gummipuppen!

Re:Poll: Where do you live? by bityard on Friday February 04, 2022 @04:36PM (#30213619)
This is literally the best comment I've ever read on this site.
Re:Poll: Where do you live? by 101008 on Friday February 04, 2022 @07:14PM (#30215466)
Thank you so much. I can sell you the NFT of this comment if you want. Or you can sell it to me I guess.
Re:Poll: Where do you live? by Crosseye_Jack on Friday February 04, 2022 @03:34PM (#30212708)
Can he help stop my Microwave from blinking 12:00 all the time?
Re:Poll: Where do you live? by geocrasher on Friday February 04, 2022 @04:24PM (#30213469)
Just do it in Bash, of course! Take the poll andcopy/paste it directly into a file called 'hnpoll', then run

   sed -e ':a;N;$!ba;s/\n/ /g' -e 's/points/,/g' -e 's/point/ ,/g' -e  's/,/\n/g' hnpoll | awk '{ print $2 " "$1 }'  | sort -n | grep ^[0-9] | tail -n 20
12 Finland

12 Serbia

13 Norway

13 Romania

15 Belgium

15 Israel

15 Spain

16 Austria

19 Switzerland

20 Italy

21 India

22 Australia

22 Denmark

26 Brazil

26 Poland

35 Netherlands

36 Sweden

41 France

124 Germany

132 Canada

See- easy!

And if you want the US states, even easier:

    grep US -A1  hnpoll  | sed  -e ':a;N;$!ba;s/\n/ /g' -e 's/points/,/g' -e 's/point/ ,/g' -e 's/,/\n/g' -e '/^$/d' | sort -r |cut -d: -f2 | awk '{ print $2" "$1 }' | sort -n | tail -n 20
15 Arizona

16 Michigan

16 Minnesota

16 Ohio

16 Wisconsin

17 Maryland

18 Georgia

25 Florida

28 Jersey

31 Virginia

32 Pennsylvania

35 Oregon

39 Carolina

42 Illinois

47 Massachusetts

51 Colorado

59 Texas

103 Washington

110 New York

265 California

And people say Bash is a terrible language...

BUT WAIT THERE'S MORE!

Get the total number of US results:

   echo $(grep US -A1  hnpoll  | sed  -e ':a;N;$!ba;s/\n/ /g' -e 's/points/,/g' -e 's/point/ ,/g' -e 's/,/\n/g' -e '/^$/d' | sort -r |cut -d: -f2 | awk '{ print $2 }' | sort -n | grep ^[0-9] | paste -sd+ - | bc)" United States"
943 United States

Combine them a bit...

   sed -e ':a;N;$!ba;s/\n/ /g' -e 's/points/,/g' -e 's/point/ ,/g' -e  's/,/\n/g' hnpoll | awk '{ print $2 " "$1 }'  | sort -n | grep ^[0-9] | tail -n 20; echo $(grep US -A1  hnpoll  | sed  -e ':a;N;$!ba;s/\n/ /g' -e 's/points/,/g' -e 's/point/ ,/g' -e 's/,/\n/g' -e '/^$/d' | sort -r |cut -d: -f2 | awk '{ print $2 }' | sort -n | grep ^[0-9] | paste -sd+ - | bc)" United States"

12 Finland

12 Serbia

3 Norway

13 Romania

15 Belgium

15 Israel

15 Spain

16 Austria

19 Switzerland

20 Italy

21 India

22 Australia

22 Denmark

26 Brazil

26 Poland

35 Netherlands

36 Sweden

41 France

124 Germany

132 Canada

943 United States

Re:Poll: Where do you live? by barbazoo on Friday February 04, 2022 @04:20PM (#30213394)
This made me almost spit out my tea, well done :)
Re:Poll: Where do you live? by stepri on Friday February 04, 2022 @07:52PM (#30215792)
I've also made a page with a map (World and US States) and tables: https://stevenprins.com/snippets/hn-where-do-you-live
Re:Poll: Where do you live? by iechoz6H on Friday February 04, 2022 @03:49PM (#30212974)
Could you ask him about random list generation too? And whether or not order influences outcomes? Thanks
Re:Poll: Where do you live? by aksss on Friday February 04, 2022 @03:25PM (#30212572)
I have a cousin twice removed who knows FoxPro and could do this.