Socialism is incompatible with human nature - <AUTHOR> https://www.spectator.co.uk/2019/11/the-rise-and-disastrous-fall-of-the-kibbutz/ <comment><USER2> I very much disagree with the fact that any kind of political and economic system could be "compatible with human nature", which is a popular argument in supporting the currently dominant liberal democracy.

Firstly, politics and economics are extremely complex high-level concepts that can't be directly tied to primal, genetic properties. If they were - why did we go through so much history and different socioeconomic structures before we got here? Wouldn't it make sense that the further back you go, the more "compatible with human nature" the social structures are?

Secondly - being in line with human nature is not a good metric. Being violent, sexual and emotional are all natural instincts, but we don't encourage people to follow them. Quite the opposite - we consider it a virtue to be able to control them and instead act rationally.

<comment><USER3> > Wouldn't it make sense that the further back you go, the more "compatible > with human nature" the social structures are?

Well, if you go back to social structures that have really stood the test of time, it turns out that they didn't scale beyond 150 individuals. That's the limit that human nature places on naïve 'anarchy' working - in order to scale beyond that, you need some sort of structure for dispute resolution and decision-making, at the very least. Liberal democracy generally makes it a point of being as 'free' as possible - that is, as close as possible to that original, tribalistic model.

</comment></comment><comment><USER4> I see no way this article will lead to a useful comment section on HN, but I'd like to throw in my 0.02 that "human nature" is not fixed - we are social mammals that are made of stories and shaped by complex webs of inter- dependencies and cultural learnings among other things.

In short humans are made, not born, and the socioeconomic systems they live within can create different humans.

<comment><USER5> Humans are born and made.

We are humans in part through evolution. Concepts like fairness are actually hard-coded in us (cannot find a reference at the minute but I remember reading research on this) : we evolved to live in a group and we are sensitive about how work and benefits of work are shared in the group.

E.g. if we spent efforts and time growing crops we will 'naturally' object to giving the produce away or to share it with someone who didn't adequately contribute or who don't somehow help us in exchange.

There are also other evolved biological aspects at play like seeking our own survival and that of our offsprings over that of other, unrelated individuals. So we also 'naturally' have a tendency to self-interest (which extends to relatives).

All of these are directly relevant when attempting to create a socialist society.

<comment><USER4> I could equally say we evolved to live in a group and therefore we tend to be highly concerned with inequality and fairness - often we value relative equality even more than we would value a higher standard of living - see The Spirit Level, etc, so we would be predisposed towards being happier in various socialisms (and indeed we do see happiness higher in general in industrial countries with stronger social safety nets/social welfare programs)

<comment><USER5> We do value fairness, as I mentioned. Equality of outcomes is not fairness, and it seems obvious that we don't naturally tend to value it as much or at all (see also actual results as discussed in the article, and more generally in countries that attempted to setup socialism). In fact equality of outcomes is fundamentally unfair.

Social welfare is not the same as socialism at all. That's a common misrepresentation.

</comment></comment></comment></comment><comment><USER6> I'd recommend James Burnham's " _The Managerial Revolution_ "

[https://archive.org/details/in.ernet.dli.2015.17923/page/n3](https://archive.org/details/in.ernet.dli.2015.17923/page/n3)

The gist being that the capitalist/socialist arguments--the ones we continue to wear into the ground--ceased to describe reality a very long time ago, and that real power is now concentrated in the hands of high-leverage organizational men: technicians, managers, bureaucrats, executives, etc.

I've seen his thesis play out so many times in business--where the owner is terrified of what his top salesman, or best engineer might or might not do. Imagine what would happen to Google if their top search guys just walked out one day. Basically, we have a participant who is technically a wage-laborer, yet has more power than an owner. This is even reflected in the share rights (or lack thereof) for many companies.

Outside of local restaurants and developing countries, long gone are the days of the "bourgeois capitalist"\--who knew his business from top to bottom-- managing unskilled laborers who were as interchangeable as nuts and bolts.

<comment><USER3> And yet, these highly-managerial firms do generally outcompete their smaller- scale rivals. Clearly, the advantages of increased scale are more than enough to compensate for its drawbacks, at least in many cases.

<comment><USER6> That's the point. The "highly-managerial" firm is the present and the future, and in that kind of firm, the capitalist/socialist bourgeois/prole framework is an inaccurate model.

They're like mini command-economies, each with its own commissars, competing with other mini command-economies, subcontracting some parts of their activity to tiny " _bourgeois capitalist_ " enterprises, and others to modern-day slave plantations.

I think Ted Chiang called them the original paperclip-optimizers.

</comment></comment></comment><comment><USER7> Then we need better humans.

<comment><USER8> Yeah... um... good luck with that.

We actually need systems that work with the humans we have, not with the humans that someone thinks we _should_ have.

<comment><USER7> I think a lot of our misbehavior is cultural and can disappear with time, if we just organized the society in a way that rewards cooperation over competition and the collective good over the individual's.

<comment><USER8> "Perfect the environment, and we'll get wonderful humans" has enough truth in it to make it dangerously wrong.

Yes, bad environments harms people - physically, emotionally, and also morally. But perfect circumstances still leave all the selfishness, foolishness, and moral faults of human nature. The perfect circumstances just leave them more room to be selfish.

You can see this in US politics, for example. The nation has rarely been this prosperous and unthreatened. And what happens? Our politicians turn into bickering children.

<comment><USER7> > The nation has rarely been this prosperous and unthreatened

This is not quite true. While the average income may be higher, the inequality is also much higher and quality of life has decreased for a large part of the population. On the politicians turning into bickering children, one can also blame the lack of oversight and flawed districting system that robs large populations of representation and removes a lot of accountability.

The country has also been continuously at war for pretty much all of this century - not quite war, but more like colonial policing, which is a political hot potato.

</comment></comment></comment></comment></comment><comment><USER9> This article while interesting is so oversimplifying things..

How about social security? Public hospitals? Public schools? History has shown that these 'socialist' institutions can work and IMHO can be better than raw capitalism but it's not easy. I'm French and our public hospitals are 'under attack', it's quite possible that they will be replaced by private hospitals.

Some say because public hospitals are too costly other because private hospitals make money and buys politicians..

</comment><comment><USER10> This is one of the most simplististic, reductionary arguments against socialism I have read. Anyone who uses the 'human nature' argument shouldn't be taken seriously. Especially with this article's mischaraterization of socialism in the first place.

The idea that all of human nature can be boiled down to only the 'selfish' and 'greedy' traits is pretty insulting, and in this case, propagandistic.

We really shouldn't continue nurturing the selfishness and greed traits on a mass scale as we currently do.

Socialism is never about people working for free or forcing lazy people to work. Its about workers owning the means of production. Giving workers dignity and eliminating the oppresive employer - employee relationship. Slave owners also thought that they were unfairly being "forced" to give up their freedoms of owning people.</comment>


Type system - <AUTHOR> http://x64dbg.com/blog/2016/12/04/type-system.html <comment><USER2> I think x64dbg (which contains a x86 and x64 interactive debugger), is the best interactive debugger available right now. Although the plugin interface isn't quite as nice as that of immunity, and because of that mona.py hasn't been ported by anyone afaik (which is a big shame imo).

But x64dbg more than makes up for it in performance (over both ollydbg and immunity) and feature completeness (multi-architecture, graph view like IDA, neat search functionality like search current region (very nice when dealing with JIT code), etc.)

If you're even a little bit into reverse engineering on Windows be sure to check x64dbg out, it blows olly and immunity out of the water imo.

<comment><USER3> Unfortunately there are no plans to support Linux :(</comment></comment>


Hugepic - a web app for showing massive pictures - <AUTHOR> http://www.peterbe.com/plog/introducing-hugepic.io

<comment><USER2> This is really, really cool. An obvious use of it would be for someone to upload that one massive xkcd: <https://xkcd.com/1110/>

A couple people have already mentioned what would be my first suggestion for improvement, which is change the URL less often, so the back button works. I'd also suggest not having an animated transition when new tiles load. It makes it take longer for the image to properly display, and is, IMHO, distracting.

Also, Leaflet (or your app?) seems to assume it's working with an image that repeats horizontally, which isn't actually the case with many of the pics on your site. It would be nice if it didn't wrap or allow going beyond the boundaries of the image.

Thank you for sharing your code. Is there supposed to be a license file? I couldn't find one in the repository.

RQ looks amazing. I'd love to tinker with all the stuff you used to make this.

I think you've created an excellent interface for browsing large, high- resolution images. Well done.

<comment><USER3> Thank you!

I started this project before that brilliant XKCD drawing. It inspired me to look at LeafletJS as an alternative.

I don't know how to switch off the vertical overlap-scrolling. Perhaps there's an option in the API. Will try to take a look.

</comment></comment><comment><USER4> It's pretty awesome! One thing I noticed is that it breaks the browser back button. I see you have some sort of coordinates in the URL, however changing these doesn't seem to do anything?

<comment><USER5> They do if you refresh the page, but doing something like this is a nightmare because it floods your browsing history with useless junk.

This should be changed immediately.

<comment><USER3> It has been fixed. The hashing thing was naive. Now it's only switched on if you start the viewing with a coordinates hash.

</comment></comment></comment><comment><USER6> There's a similar service called zoom.it (based on Deep Zoom), but it doesn't seem to be taking uploads anymore.

<http://zoom.it/> (some examples on the right)

<comment><USER3> I did not know about that. Thanks for pointing it out.

I had so much fun building this that I don't mind discovering existing wheels lying around.

</comment></comment><comment><USER7> The current maximum zoom level (I think it's "5" from the url) seems too low for some of the pictures. For example, this shot [1] from the picture "Nick Field" is zoomed to the maximum level but looks like it could zoom quite a bit more while still having a useful level of resolution and quality.

[1] <http://hugepic.io/35f881f45#5.00/80.636/-135.923>

<comment><USER3> It's capped at 5 I think. Zoom level five corresponds to a width of 8,192 pixels. Zoom level 6 would be 16,384 pixels. And the Nick Field picture is only 10,768 pixels wide.

</comment></comment><comment><USER8> Someone should upload the zebrafish image to this.

[http://v.jcb- dataviewer.glencoesoftware.com/webclient/img_de...](http://v.jcb- dataviewer.glencoesoftware.com/webclient/img_detail/201/)

</comment><comment><USER9> I would never use a website that broke the back button this badly unless it offered some tremendously essential feature for my daily life.

The way it shows blackness at the bottom of the image but not the top is pretty weird also (tried it with the really wide, but not very tall test image). I think every margin should be the same color.

Scrolling and zooming feel pretty smooth, but it glitches and refreshes the entire screen when you cross over a horizontal boundary (when the image is wrapped).

<comment><USER3> Sorry about the back button thing. It's been fixed now.

I never really noticed it because I never navigated like that when I developed it. #homeblind

</comment></comment><comment><USER10> Pretty cool!

<comment><USER3> Thanks!</comment></comment>


After $9 Billion Loss, Trader Revives Career - <AUTHOR> http://online.wsj.com/article/SB10001424052748704621204575487182419639738.html

<comment><USER2> I was about to be "invested" in the story, until i remembered that the $9 billion he lost was other people's money..

</comment><comment><USER3> 1\. Gamble away financial stability

2\. Profit!

3\. Charge victims money to avoid losing all their money

4\. Profit!

5\. ???

6\. Profit!</comment>


Lessons learned building a toy compiler - <AUTHOR> https://jaseemabid.github.io/2017/07/04/compiler.html <comment><USER2> I love seeing articles like this... my compiler design course in college was one of my favorite. Also, one of the most useful. Parsers and lexers are useful in so many places besides just code compilers.

With that said, I think there is one small issue in the article:

> The quintessential first step in any compiler is parsing the source string > into an Abstract Syntax Tree

If there is a quintessential first step in writing a compiler it is doing lexical analysis with a lexer to break the program up into tokens. Then using a parser to create the AST. While you could go straight from the raw text to parsing, it makes it a lot easier if you lex it first.

<comment><USER3> Well you can do both at the same time, it is called local lexing: [https://arxiv.org/abs/1702.03277](https://arxiv.org/abs/1702.03277)

<comment><USER2> I did mention in my post that the separate lexing step is not strictly necessary. I was just pointing out that a lexer follows the definition of "quintessential" more than parser does.

That paper is very recent. It sounds like it is still doing both steps just concurrently and with feedback. It isn't skipping the lexing step altogether. The benefit of separation is decreased code complexity and easier debugging.

<comment><USER3> Yes, both stages are still present in that approach, and that is a good thing, because clearly it is useful to separate lexing and parsing. It's just that the two stages are intertwined and thus lexing can be dependent on the parsing context. So it is not really going from "raw text to parsing".

</comment></comment></comment></comment><comment><USER4> It's nice to have a small example of how to compile to LLVM, but the compiler is a bit more limited than what the blog post makes it appear.

It's not quite `a compiler for simply typed lambda calculus', but only for a small fragment without higher-order functions. One currently cannot write lambda terms that take functions as arguments.

I was curious how the compiler represents closures and manages memory, mainly because I'm looking for a small example of how to do garbage collection in LLVM. But it turns out that the parser doesn't allow function types yet and the compiler itself doesn't implement closures yet.

<comment><USER5> You are right, the compiler cannot handle much of higher order functions and closures yet. I have hinted how to do that with lambda lifting and closure conversion and I might get it working in the next few weeks. Maybe a part 2 for the blog post.

<comment><USER4> Yeah, do it! :)

</comment></comment></comment><comment><USER6> I think the most underrated part is: "untyped lambda calculus is harder"

<comment><USER5> You read my mind :D

</comment></comment><comment><USER5> Author of the post here. AMA :)

<comment><USER7> Hello there! Great post :)

I never took a course in writing compilers at University but have always been interested - where would be the best place to start for somebody interested in doing this? To dip their toes into the water if you will?

<comment><USER5> Just tinkering with the tools and writing some code helped me a lot more than the university course I had 6 years ago. There are several beginner friendly online resources now including

1\. Write a scheme in 48hrs in Haskell

2\. Kaleidoscope tutorial by LLVM developers

3\. [http://www.buildyourownlisp.com](http://www.buildyourownlisp.com)

4\. [http://createyourproglang.com](http://createyourproglang.com)

<comment><USER8> I would also add 5.[http://dev.stephendiehl.com/fun/](http://dev.stephendiehl.com/fun/)

</comment></comment></comment></comment><comment><USER9> I remember building funny little DSL-Tools with flex and bison. [https://github.com/westes/flex](https://github.com/westes/flex)

I used it for AutoSar applications, where you create tailored embeded programs from a DSL specification.

</comment><comment><USER10> Perhaps before diving into FFI, you could write a small runtime library with the basic I/O you need (`readline` and `puts`, perhaps?)

<comment><USER5> I did exactly the same last night and you don't need the echo $? hack anymore.

</comment></comment><comment><USER11> Great post! Interested, how it's related to, for example, Scheme or Lisp.</comment>


The Unspoken Truth About Managing Geeks (2009) - <AUTHOR> http://www.computerworld.com/s/article/print/9137708/Opinion_The_unspoken_truth_about_managing_geeks?taxonomyName=Management&taxonomyId=14

<comment><USER2> I call it "herding cats".

Definitely an uncommon skill, and the top 1% are not even good enough.

</comment><comment><USER3> I find "managing geeks" to be about as offensive as an 1850 book about "managing niggers".

"geek" is a term that is used to suggest that technical people are somewhat subhuman and of course inferior to managers.

<comment><USER4> I do not see the negative connotations that you do with the word "geek". I describe myself as a geek or geeky.

That aside, the article is a good one and I have read it several times before and feel that it gets much right.

<comment><USER5> The term has evolved over time, but it definitively had negative connotations, at least at the beginning.

From the Wikipedia article> This word comes from English dialect geek or geck (meaning a "fool" or "freak"; from Middle Low German Geck)... In 19th century North America, the term geek referred to a performer in a geek show in a circus, traveling carnival or travelling funfair sideshows (see also freak show).</comment></comment></comment>


GCC Function Multiversioning - <AUTHOR> https://gcc.gnu.org/wiki/FunctionMultiVersioning

<comment><USER2> I wanted to give it a try, but if fails without considering the target attribute ...

> gcc test.c -g > test.c:9:5: error: redefinition of 'foo' > int foo () > gcc > version 4.9.2 (GCC) (archlinux)

<comment><USER3> It's not entirely clear, but I think this is a C++ only feature that is only available when using the GCC C++ front end (g++). The linked document includes the ambiguous "Support is only available in C++ for i386 targets", but other sources (such as the GCC 4.9.2 documentation) have clarified this to "With the GNU C++ front end, for target i386, you may specify multiple versions of a function".

[https://gcc.gnu.org/onlinedocs/gcc-4.9.2/gcc/Function- Multiv...](https://gcc.gnu.org/onlinedocs/gcc-4.9.2/gcc/Function- Multiversioning.html)

<comment><USER2> indeed, my bad! to my defense, the code looks a lot like C code ;-)

</comment></comment></comment><comment><USER4> Looks like gcc is also generating a dispatcher function. This should really be the runtime linker's job. Solaris has been able to do this for as long as I can remember.

<comment><USER5> One problem with doing it in the runtime linker is that the implementation needs to get it right to allow programs to run with a runtime linker that doesn't support it. And that would not work on e.g. Windows.</comment></comment>


$80 Android Phone Sells Like Hotcakes in Kenya, the World Next? - <AUTHOR> http://singularityhub.com/2011/08/16/80-android-phone-sells-like-hotcakes-in-kenya-the-world-next/ <comment><USER2> It isn't a smartphone, it's a computer. This is the real "one laptop per child".

It is truly disruptive: in 1.5 years (Feb 2013), that $80 will buy twice the RAM, processing power, flash etc (or sooner, as they may well beat Moore's law via economies of scale).

Wow, I got shivers up and down my spine at the _Medkenya_ : as usual, disruptive platforms carry disruptive applications atop. This can really change the world. All the great things that computers can do, these "smartphones" can do - not just angry birds.

Apple can't compete here, because they are only interested in cutting-edge technology that will not work unless it is put together with great ingenuity. It's essential that someone lights the way as Apple does; but it does mean that they have to keep inventing the next new thing to remain viable.

 _EDIT_ oddly, they are priced $176-249 here in Australia (our AUD is currently worth 5% more than the USD). Guess it's priced by market. And of course, you still need to pay for connectivity (I wonder how much that costs in Kenya?). A review and specs: [http://www.pcworld.idg.com.au/review/mobile_phones/huawei/id...](http://www.pcworld.idg.com.au/review/mobile_phones/huawei/ideos_u8150/363402)

<comment><USER3> the 3GS is only $45 on AT&T. Some carriers overseas are offering the iPhone 3GS/4 for free (with a contract of course).

Not to diss Android, but iOS devices have better apps, better battery life, etc.

<comment><USER3> all i'm saying is it would be nice if these users can at least have a great first-time user experience without having to worry about their phones crashing , running out of battery within 30 min. of use, or getting malware and trojans on their Android phones.

<comment><USER4> Why I feel that I am reading Engadget? This is not the kind of comment that I expect to read on HN.

</comment></comment></comment></comment><comment><USER5> I work in Rwanda (<http://www.nyaruka.com/>) and we're currently doing a project for an NGO that is using the Ideos for a variety of different things, the pricepoint really is amazing.

For one, we're using them to act as SMS gateways to generate activation codes. Essentially they receive confirmation messages for mobile payments to a particular number and we wrote an Android app that generates a unique activation code and sends it back to the payer. Better than a PC because it's cheap, has redundant power, redundant network and better connectivity with the GSM world.

The other task we're using them for is to act as network attached barcode scanners for inventory control. Essentially using the camera to read QR codes and allowing people to move / receive / send inventory using a rich app interfacing to the cloud based backend we are building. They are amazing for that.

I guess my point is that this isn't just a milestone for the consumer, it is a milestone to have an easily programmable, portable, GSM connected device with a camera and a touchscreen that only costs $80. Nothing else compares.

<comment><USER6> I do have one worry about this though. If this is the only "computer" a lot of people can afford, this is going to mean that the bulk of a generation is going to grow up without access to computers they can program themselves. Maybe I'm just being alarmist, but growing up all our family's computers were also programmable, so I went from basic to c to c++ all on the same machines dad used for Word Processing. Losing all that for the convenience of mobile seems like a questionable trade.

<comment><USER7> You are assuming that people in the developing world can afford a computer just as easily. The importance of having an information device that connects to the internet cannot be overstated in places where education is not the primary concern. Early access to technology will inspire many more kids to learn programming when they can afford one.

<comment><USER6> I agree there are some strong upsides, but phones make it difficult to participate in a meaningful way at the higher levels of the information economy. They're consumption-oriented devices. Here in Vietnam I see a lot of people that have blown their entire computing budget on a high-end mobile phone and I worry that they may have stunted the growth of some of their talent as a developer, writer, artist etc.

I realize that developers are rare but the money my grandfather invested in a C64 in 1983 has been repaid many, many times over. I'm not sure I would have the same incentive or opportunity to learn now.

</comment></comment></comment></comment><comment><USER8> Hi, kenyan guy here. I bought the ideos 3 months ago. Love the android OS, I'm writing this using swype n what a breeze. the battery life off the phone is a but of an issue but if u disable things like GPS then you can get almost a full day worth of charge.

About data plans, i usually subscribe to 10MB per day at a cost of 8shillings(about 0.1 of a dollar). Though you can subscribe to 25MB pet day at cost of 0.25 of a dollar. You can also subscribe to unlimited data plan for 30 dollars per month. Of course this are figures for my carrier but those from other carriers don't differ by much.

I can say most people will move to android (at least my friends are planning to after seeing my apps). I mean, they were impressed by th fact that they can listen to any song using my jango android app.

<comment><USER9> I'm Kenyan too (in the diaspora, though) and I've been amazed by how quickly and thoroughly some mobile technology has spread back home. Services like mPesa that enable mobile payments are actually much better implemented and more widespread than similar technologies Stateside.

Even my grandma in Githumu which for years only had telephone service from 9am-5pm (and only via an operator) now has access to mobile phones will all the trimmings.

I might even send her a new Android phone for xmas :^)

<comment><USER8> do that. Its amazing, still not sure why nokia chose microsoft over android.

<comment><USER10> Your email's not visible in your profile. Put it in the About section, sawa?.

<comment><USER8> poa

<comment><USER10> @sadq70 on twittah.sent u mail from th same handle on gmail.will be at gkenya 2.0, you?

</comment></comment></comment></comment></comment></comment><comment><USER11> I've said it before, but I'll repeat myself: Android will be the dominant OS of this decade (found in phones, tablets, netbooks and other devices) because it is the only OS that is both fully modern and flexible enough to be adapted to whatever needs people have.

One thing I'd love to see from Google is more support for "platform developers" - docs, examples, tutorials and tools to help anyone get Android up and running on different devices.

<comment><USER6> The low barrier to entry for development is going to be important too. The development tools are free and run on low-end hardware and you don't have to pay a fee to distribute apps outside the app store.

Make no mistake, this is why Apple and Microsoft are afraid of Android and it makes their selfish bullying that much more reprehensible. Apple is never going to make an $80 phone.

<comment><USER10> And Google advocating for more android developers here in kenya helps. In fact they have a dev conference next month in Nairobi and Android is one of the topic list(plus GAE,GWT, chrome).

</comment></comment></comment><comment><USER12> When I was travelling in Scotland I bought ZTE smartphone android 2.2 for 50 pounds without a contract just to use Google maps instead of paying expensive 10 pounds per day rental GPS. The touchscreen is horrible but the phone itself is pretty responsive ,Skype worked fine. Basically throw away smartphone for two weeks of vacation.

<comment><USER13> I have that phone. I run an Android 2.3.4 mod for it. I now get several days worth of battery life, multitouch and a very smooth responsive UI. That phone has proven to be a very hackable device and there have been some GREAT roms released in the last few months for that aging hardware.

<comment><USER8> Hi I have th phone, could you direct me to web resources that will guide med on how to install a custom ROM, my email is email@example.com Thanks in advance

<comment><USER14> I (probably) have the same phone as the grand-parent. Best modding info is at: [http://android.modaco.com/forum/453-zte-blade-libra- blademod...](http://android.modaco.com/forum/453-zte-blade-libra- blademodacocom/)

<comment><USER15> The Blade/Libra/San Francisco is a great phone, but it's not available for 50 quid, more like double that (though I bought mine for 70 a while ago, and got an AMOLED screen version too).

Maybe he was talking about the ZTE Racer, a previous best buy in the world of Android. Modaco also have info on getting the best out of that device:

[http://android.modaco.com/forum/454-zte-racer- racermodacocom...](http://android.modaco.com/forum/454-zte-racer- racermodacocom/)

<comment><USER13> I got my Blade/San Francisco for £75. From time to time there are deals, Argos was selling them on discount, some online retailers were too, Orange had a weekend sale on them a few months ago, and of course the second hand market. But yes you are right, they are closer to £100 than £50.

<http://blade.modaco.com/> is a real gem and truly the best place to get all sorts of roms for the phone.

</comment></comment></comment></comment></comment></comment><comment><USER16> I thought the article was a little low on content; found this one somewhat better written and more informative: <http://www.technologyreview.com/communications/37877/?a=f>

Will probably be visiting Kenya shortly, so I'm definitely going to have a look at how 'mobile' is being used over there!

<comment><USER17> When you do, totally check out MPESA and how widespread it is. Mobile payment traction that a US startup would die for.

</comment></comment><comment><USER18> FWIW, T-Mobile USA sells this same phone stateside as the Comet[1] for $125 outright.

[1] [http://www.t-mobile.com/shop/Phones/cell-phone- detail.aspx?c...](http://www.t-mobile.com/shop/Phones/cell-phone- detail.aspx?cell-phone=T-Mobile-Comet)

<comment><USER17> $79 from MetroPCS. [http://www.metropcs.com/shop/phonedetails.aspx?productid=hwm...](http://www.metropcs.com/shop/phonedetails.aspx?productid=hwm835\(phones\))

</comment></comment><comment><USER19> Fantastic to hear about computing reaching the hands of the world's poorest. I wonder if poor battery life would be an issue in areas with limited access to electricity, but this could be powerful even if it reaches the more urban areas.

I love that it has a camera. I believe that omnipresent cameraphones have been an underrated deterrent for crime and government brutality in the last 10 years (in more developed countries).

<comment><USER20> More places are picking up electricity all the time. Oddly enough, the very solar panels and wind generators that are still seen as too expensive in e.g. the US can be a HUGE help in getting electricity to remote areas.

A typical cell phone battery stores 5-7 watt hours. With good sunlight, one 30-watt solar panel might provide full charges for 15+ phones in a day. Maybe add $10-20 to the cost of each phone to get a solar charging station set up in a village?

That wouldn't be so bad, all things considered.

<comment><USER21> Solar panels are only "too expensive" in the west because:

1) the west is used to consuming a lot more electricity

2) power lines from coal plants are cheap here. There, they don't even have the plants yet.

In other words, they don't need a whole lot of juice there, and whatever other alternatives exist (if any do) are even MORE expensive.

<comment><USER5> Solar panels actually aren't a great option here believe it or not. People have been trying for a long time to get them working well and they just don't. Typical problems are theft, quick degradation from too much sun etc.. They are also pretty darn expensive.

There are other options though. One of the more interesting ones is being done by Nuru, which sets up micro-businesses of people who charge lights / phones / radios using a pedal powered generator. Those generators are really simple, last a long time and they are set up right from the start to provide an income source for the owner.

That said, smartphones aren't really viable for the 'villagers' for a while still, charging every day really isn't practical even with something like that, it is just too expensive. But there are still a ton more just above them that live in more urban environment where electricity is available, and for them cheap smartphones can really change things.

</comment></comment></comment></comment><comment><USER22> I couldn't find much about data plan pricing in Kenya, but if I'm reading this[1] page right, there are unlimited plans for the equivalent of about USD $10 per month. Really not that bad.

[1] <http://kalahari.xtgem.com/internet_tarrifs_in_kenya>

<comment><USER23> Not that bad, but only with US salary. Take into account average family income in Kenya.

<comment><USER24> What kind of average family is buying an $80 cellphone? The majority are still going to use cheap used phones shipped in from the EU, or discarded by the richer members of their society.

<comment><USER25> I'm assuming that most of the people in Kenya buying a smart phone are going to be on the upper end of the income distribution.

</comment></comment></comment></comment><comment><USER26> Why no mention of that badly photoshopped image of the girl supposedly holding the phone?

[http://singularityhub.com/wp- content/uploads/2011/07/Kenyan....](http://singularityhub.com/wp- content/uploads/2011/07/Kenyan.jpg)

Beneath which they say 'Hwawei's IDEOS smartphone' -- meaning Huawei.

</comment><comment><USER13> I have a variant of that Huawei phone charging in front of me. The battery life is appalling - It is charged twice a day. Luckily there are android mods that have multitouch integrated back into the rom.

However I paid €25 for it on prepay after a rebate from my operator. An incredibly inexpensive device!

</comment><comment><USER27> QVGA (320x480) is a different aspect ratio than most Android phones which are 480x800 or 480x854. The size makes it look bad, but the aspect ratio makes designing a layout that looks good on all handsets really hard. Guess which one will get left out.

<comment><USER28> When the choice is between "no smartphone" and "smartphone with suboptimal/clumsy layout", guess which one gets picked?

Not to mention that screen res and "looks good" is a specs geek problem not a real problem, anyhow. It somehow isn't stopping people (in Kenya, where I am in Australia, presumably all round the world at all economic levels) from finding these phones useful.

<comment><USER29> Have one in Australia, the aspect ratio is more of a problem for Market manifests blocking downloads than actual usage - once you get an .apk, most apps scale such that they are still usable.

</comment></comment></comment><comment><USER30> Some insightful discussion @ Berkeley TIER's mailing list

[https://www.millennium.berkeley.edu/pipermail/tier/2011-Augu...](https://www.millennium.berkeley.edu/pipermail/tier/2011-August/003045.html)

</comment><comment><USER31> Does anyone know of a cheap Android phone that can run Flash 10.1 comfortably?

<comment><USER32> my $3400 macbook doesn't run Flash comfortably

</comment></comment><comment><USER15> The computer for the rest of us?

</comment><comment><USER33> The title of this article tells me nothing. The real question is, how well do hotcakes actually sell in Kenya?

</comment><comment><USER34> Why do we care about a $120 difference in the cost of the handset when you are going to sped at least $1600 on a contract over the 2 years you are required to sign it for?

Maybe I'm missing something, but I don't understand why anyone cares about the prices of phones (unless they're outrageously high i.e. the original iPhone's $500).

<comment><USER35> This is not the pricing model used in African countries. So the price of the handset does matter.

As I understand it, most mobile phones in Africa are pre-paid, using per- second billing.

</comment></comment><comment><USER36> $80 in Kenya, with probably market-rate voice and data (ie, reasonably cheap) will never see the light in the USA.

First you have the IP battles (patents, trade-dress, etc), then you have a consolidated and generally anti-innovation telecom monopoly.

What will happen is that the feature and dumb phone will be killed by cheap Androids... this will be mildly threatening to (currently) weak smartphone lines like WP7 and Blackberry, but will leave the iPhone unscathed for the near future.

Any prognostication more than 2 years out is useless (what happens when the real FacePhone hits?)

<comment><USER37> USA customers tend to compare unsubsidized phones to subsidized ones, and seem surprised when the $150 product isn't as good as the $600 one.

<comment><USER38> Not as surprised as they are when they realize how much they paid for the expensive phone, in my experience. Regardless of brand, it's baffling to me why people don't just wait a few months and buy a phone outright instead of getting the one with the very expensive contract.

Have you seen that MetroPCS commercial where the dumb kid takes the glittering gold phone only to to find himself swinging from a rope while the presenter admonishes 'Silly Billy! The _contract_ is how the trap is sprung!' They should get some sort of award for promoting financial literacy at the same time as marketing their service.

<comment><USER39> If you buy a phone outright you still have to pay the same high monthly rates.

<comment><USER38> I pay $50/month for my line and another $35 for my wife. I don't spend a lot of time on the phone and I don't text at all, but I have unlimited data. More importantly, I barely bother to look at my bill because I know what it's going to be in advance. The lack of admin more than makes up for any minor economic inefficiencies - I don't grudge the phone company making a profit off my relative underuse of the voice service.</comment></comment></comment></comment></comment>


From SQL injection to shell: PostgreSQL edition - <AUTHOR> https://www.pentesterlab.com/from_sqli_to_shell_pg_edition.html

<comment><USER2> be sure to read the prequel if you haven't done anything like that before: <https://www.pentesterlab.com/from_sqli_to_shell.html>

</comment><comment><USER3> If I use sql parameters in my queries, am I still vulnerable to SQL injection? What about using a (sane) ORM?

Basically, is it only php apps that hand-build queries that are vulnerable to SQL injection?

<comment><USER4> Any app that hand-builds queries. PHP has nothing to do with this. Just happens to be the vehicle. The problem is simply insecure patterns.

</comment></comment><comment><USER5> What if I have no PHP?)</comment>


Apple Approves an App That Blocks Ads in Native Apps, Including Apple News - <AUTHOR> http://techcrunch.com/2015/10/06/apple-approves-an-app-that-blocks-ads-in-native-apps-including-apple-news/#.6qjorz:cICn <comment><USER2> Maybe that's it for the freemium model? We tend to forget that before the web most software had to be paid for unless it was pirated or unpaid shareware. The advertising model has given us everything from the original Star Trek television series to Google, but maybe this is the downturn of that model.</comment>


Raspberry Pi Motion Sensor with Realtime Web Alerts Tutorial - <AUTHOR> http://www.pubnub.com/blog/building-a-raspberry-pi-motion-sensor-with-realtime-alerts/

<comment><USER2> >Thanks to its open software and hardware designs, the Raspberry Pi is well- suited to demonstrating the core tenants of the IoT. On a Pi, a tinkerer has full control. They can connect actuators and sensors, process data, and send information over a WiFi connection.

Using a 1ghz, 512mb RAM + WiFi at a price point of ~$50 USD does not constitute "core tenants of the IoT", irrespective of how fluid the term "IoT" is right now.

For a little more than cost of this article they could have deployed a targeted giveaway program with the ESP or (even more friendly) ElectricImp modules preconfigured with their service.</comment>


Haskell vs Clojure syntax - <AUTHOR> http://honza.ca/2013/02/haskell-vs-clojure-syntax

<comment><USER2> > ( * ) <$> Just 2 < * > Just 8

I would have written "Just 16."

> Nothing >>= \x -> return (x * 10)

I would have written "Nothing." Actually, that about sums it up.

 _Edit_ : just to expand on the above with some commentary, his examples are all basically as if he saw a salad in a bag, decided he wanted a salad, and proceeded to buy all the ingredients from separate bags, stick them in one big bag, open them all from inside the other bag and mix them together. In practice, you just don't need to do things this way.

The first example is treating Maybe as an applicative functor. In practice, when someone does this, they don't use a bare operator like ( * ). Suppose I want to read in an integer from the user. Which is easier to understand?

        x <- getLine >>= return . read

or

        x <- read <$> getLine

This is the usual way <$> is used, not his way. You could even get some mileage out of using monads with the do notation, by doing something more like:

        x <- getLine
        return $ read x

Same with the next example:

        x <- Just 2
        y <- Just 8
        return $ x * y

but there's no intrinsic reason to instead write that as he did.

Similarly, his second example reads much better when you consider the do notation:

        x <- Nothing
        return $ x * 10

In fact, even using the syntax he proposes on the other line produces a more readable example:

        Nothing >>= return . (*10)

If you don't understand what's going on with his second example, you should brush up on monads. You don't need to understand applicative functors to get things done, but they do make life better when used in moderation.

</comment><comment><USER3> It would have been more compelling if the author exhibited two code snippets that do the same thing.

In the Clojure example, he adds two numbers together, defines a function that modifies a string by prepending "Hello " and defines a constant.

In the Haskell example he overloads the `pure` and <*> functions to work on the 'Maybe' type, allowing arbitrary functions to be lifted into 'Maybe' to allow automatic propagation of failure.

<comment><AUTHOR> I know some Clojure and barely any Haskell at all. I opened up "Learn you a Haskell" and copied and pasted a few code samples that appeared to have strange syntax. The idea of the post was to show the difference in the amounts of syntax in the two languages.

<comment><USER3> You know 'some' of language A and 'barely any' of language B, and you thought it would be a good idea to write a blog post comparing them and post it to HN?

</comment></comment></comment><comment><USER4> This has to be the shallowest possible analysis you could have given this issue. No explanation of the tradeoffs or exploration of why they took the routes they did. Just, "Haskell has, like, syntax man. Syntax is hard."

Additionally, the explanation of Clojure syntax is woefully incomplete — going by this article, {:age 1} and #inst "@2012-02-12T01:02:03.456" aren't valid Clojure. In reality, Clojure is very syntax-heavy for a Lisp, and most Lisps still have more complicated syntax than the simplistic "Things go between parentheses, the first of which is evaluated as a function and the rest of which are arguments" — look at just about any macro definition in any Lisp to see a fair bit of syntax beyond parentheses.

<comment><USER5> _This has to be the shallowest possible analysis you could have given this issue_

Not disagreeing here. Moreover I'm not really sure comparing these two on syntax makes a lot of sense: comparing an homoiconic language with a non- homoiconic one from the syntax point of view is weird. Then the main difference between these two languages is related to typing IMHO.

If you want the benefits of homoiconicity in Haskell, there's a Liskell project (not sure how good it is yet but it certainly is interesting).

</comment></comment><comment><USER6> That's hardly a fair comparison, the equivalent Haskell to the Clojure example is fairly similar, though my Haskell is a bit rusty at this point.

      sum = 1 + 2
      greet name = "Hello " ++ name
      usercount = 34

I'm not 100% sure what the Haskell example is trying to accomplish though.

</comment><comment><USER7> What a terrible post. Those two snippets aren't even slightly related. It's like the author is comparing a basic "Hello World" in C to some entry from the obfuscated C competition.

</comment><comment><USER8> Clojure has [] and {} and #{} and '() and #() and : and ^ and @ and Foo. and .foo and ->, ... you still have to learn them to understand Clojure code.

</comment><comment><USER9> I don't understand why such sophomoric drivel gets posted so often to hacker news.

</comment><comment><USER10> With Haskell you get to learn the crazy syntax of the standard. With Clojure you get to learn the crazy syntax of whatever program you're looking at.

<comment><USER11> Not really. The culture with Clojure is that macros have reasonably long, descriptive English names. You don't have to go digging in the documentation or source to figure out what a macro does. Haskell, meanwhile, inherits mathematical culture and abuses operator overloading to the point where you can't figure out anything code is doing without looking at the source.

I'd argue that being able to define custom operators is far, far, worse for readability than being able to define custom syntax that's invoked by an English-language macro.

<comment><USER10> Well it was sort of a lisp macro joke. ;)

</comment></comment></comment><comment><USER12> What? Haskell barely has any syntax as well. Slightly more than lisps, but nowhere near to C family languages.</comment>


Oracle euthanizes Solaris 12, expunging it from roadmap - <AUTHOR> https://arstechnica.com/information-technology/2017/01/oracle-sort-of-confirms-demise-of-solaris-12-effort/?m=1 <comment><USER2> NB: This is from January (2017).</comment>


Optimize your Node app by upgrading Node.js - <AUTHOR> https://blog.sqreen.io/optimize-your-node-app-by-simply-upgrading-node-js/ <comment><USER3> FYI: Idiomatic Javascript / Builtins should be fast with the recent revamp of the V8 engine (stop writing "CrankScript").

[http://benediktmeurer.de/2017/03/01/v8-behind-the-scenes- feb...](http://benediktmeurer.de/2017/03/01/v8-behind-the-scenes-february- edition/)

[https://github.com/v8/v8/wiki/TurboFan](https://github.com/v8/v8/wiki/TurboFan)

[https://www.youtube.com/watch?v=M1FBosB5tjM](https://www.youtube.com/watch?v=M1FBosB5tjM)

<comment><AUTHOR> You are right, some patterns (like try-catch) have been made optimizable thanks to TurboFan.

However:

* until ignition is not available by default on Node.js (now only through the --ignition flag, or using current master), a lot of these optimization tricks will stay up to date. Also, companies have a history of moving slowly to newer versions of Node.js.

* even with ignition (I just tested it), using Generators (including async functions) is an optimization killer.

<comment><USER4> Chrome's generators are still quite fast compared to Firefox. I've currently got a generator stress test in using generators to implement a lua parser: [https://github.com/serprex/luwa/blob/2c1ef6be42b804144340a2e...](https://github.com/serprex/luwa/blob/2c1ef6be42b804144340a2e8fb79cbfeb4bc9e8a/ast.js)

Currently trying to rewrite the Exp rule from using combinators to using something that'll properly handle operator precedence (Not keen on having 11 levels of operator precedence encoded in the grammar)

</comment></comment></comment><comment><USER5> Ok, seems like an interesting article but what the hell is up with those share icons. On your mobile if you rotate the screen to read the interesting table they cover up the first damn column. Then you rotate it back to portrait and they don't move back.

Fix your website. Remove those silly icons!

<comment><USER6> But irritating 90% of your audience with a distracting something that only 1% of them use is the preferred stylish design choice of the modern era.

Whether it's share buttons or an email signup...I mean heck, Europe essentially passed a mandatory website popup law for telling you about cookies.

<comment><USER7> They ended that law a while ago by the way.

[https://www.theregister.co.uk/2017/01/10/brussels_announces_...](https://www.theregister.co.uk/2017/01/10/brussels_announces_death_sentence_for_cookie_popup/)

</comment></comment></comment><comment><USER8> The new major version 8 of Node.js coming out in April will be a great performance booster for those who started using async/await and more:

\- Node upgraded v8 to 5.7 [1] & async functions as fast as promises [2]

\- Optimizations in fs[3]

[1] [https://github.com/nodejs/node/pull/11752](https://github.com/nodejs/node/pull/11752)

[2] [https://v8project.blogspot.ca/2017/02/v8-release-57.html](https://v8project.blogspot.ca/2017/02/v8-release-57.html)

[3] [https://github.com/nodejs/node/pull/12105](https://github.com/nodejs/node/pull/12105)

</comment><comment><USER9> > Object literal containing a getter and object literal containing a setter

Isn't this something Babel does quite often?

</comment><comment><USER10> According to the table, there are an increasing number of constructs that prevent optimization. The oldest versions of node seem to have no constructs that prevent optimization. Can that be right?

<comment><AUTHOR> The sentence before the table is mistaking. We are updating it. It should be read in the other direction: if the cell contains "yes", the code pattern is optimizable.

Thanks a lot for your remark!

<comment><USER11> but only a few contain yes, so most aren't optimizable?

<comment><AUTHOR> yes, that's the case.

</comment></comment></comment></comment><comment><USER12> I find the (repeated) use of the word polymorphism here a bit confusing...

I'm mostly used to it an class inheritance-related contexts. Is it used differently in the Node/JS-community?

<comment><USER13> This is a different notion of polymorphism, yes.

Suggested reading: [http://mrale.ph/blog/2015/01/11/whats-up-with- monomorphism.h...](http://mrale.ph/blog/2015/01/11/whats-up-with- monomorphism.html)

</comment></comment><comment><USER14> I'd really like to find a position doing more Node development. It seems like every place in my area that claims to just uses npm. I've had to learn the MEAN stack on my own, and it feels like it outperforms a lot of the apps I've built in other stacks.

<comment><USER15> Look into remote jobs. Plenty of people that need skilled node developers.

<comment><USER16> Can you name a few? I'm looking.

<comment><USER17> Hustle Inc: we are looking for nodejs devs, have an entirely modern stack, es6+, react, react native, etc...

If you love JavaScript we want you to work with us. Drop me a line through my profile.

<comment><USER14> The only thing I'm not as familiar with is react, I've spent most of my time learning Angular 2 lately. And as I've mentioned, I haven't ran into a lot of people looking for these more modern skills. Is there more companies looking for react than Angular?

</comment></comment></comment></comment></comment><comment><USER18> A quadratic algorithm optimized by v8 will be still quadratic.

While these optimizations can be helpful, real problem is order of growth. To optimize order of growth problems knowledge of algorithms and data structures is important.

Optimization can be assisted by instrumentation and profiling.

<comment><USER19> > A quadratic algorithm optimized by v8 will be still quadratic.

That's pretty obvious. An engine's optimization features are there to help execute code faster, not as a substitute for knowledge about algorithms and data structures. The implication here is that being respectful of _both_ solid CS theory and an engine's optimized patterns allows you to benefit from both, not just one or another.

<comment><USER18> I had an application with a performance bottleneck once, and people kept telling me that the solution was to upgrade node.

I ignored them, ran a profiler, found a bottleneck and fixed the bottleneck.

Sounds obvious but not everyone is familiar with performance optimization.

<comment><USER19> Out of curiosity did you also check to see if upgrading node would've also been to your benefit? It could just be a side-effect of working at a large company with smart people, but if "people" are telling me the solution is an upgrade I wouldn't be doing my due diligence to ignore them all.

Not trying to invalidate the fact that you found a way to enhance performance via profiling - that's great! But the way you phrased your response seemed very condescending of "people" when there may have been truth to what they said.

</comment></comment></comment></comment><comment><USER20> > the JavaScript engine will not accept to optimize it

What does this mean? I don't understand if it's good or bad. Sounds bad but seems good according to the table?

<comment><AUTHOR> This misleading part of the article has been updated for more clarity.

The concept of non-optimization is describbed in my previous article: [https://community.risingstack.com/how-to-find-node-js- perfor...](https://community.risingstack.com/how-to-find-node-js-performance- optimization-killers/)

tl;dr: you want to avoid patterns that prevent optimization: the ones with a red "no" in the table.

</comment></comment><comment><USER21> Unrelated and I'm sorry for that, but do you know of a good way to get rid of the scroll hijacking? I didn't find a lot of extensions for Chrome and the one I tried wasn't working.

It blows my mind to encounter this bad practice on a developper related website.

<comment><USER22> In this case, it can be fixed by running this in the developer tools:

        getEventListeners(window).wheel[0].remove()

<comment><USER23> That did it for me, thanks. Seriously, who overrides default scrolling behavior?

<comment><USER15> People that develop on windows and want that smooth mac style scrolling - <USER2> least from my experience. Also LOTS of free and paid wordpress themes use it as a selling point.

</comment></comment></comment></comment><comment><USER24> I was at first excited, then deflated, because I initially read the headline as "Optimize your Node app by deleting Node.js" (snerk).</comment>


Ask HN: Working on startup on work issued computer - <AUTHOR> I am working on a bootstrapped startup on my nights and weekends while maintaining my big corp job. The only computer I have is my work laptop, so I have been using that for everything. Could I run into issues if I get a startup to the point of success and profits and then quit my job?<p>FYI: I am in CA and my startup is in no way related to what I work on at my day job. <comment><USER2> Do. Not. Do. This.

For elaboration, here's your risk/reward calculation. Reward: you save N days worth of your present salary which you should spend on a cheapo laptop. Risk: you are planting an unrecoverable flaw deep in the heart of your company. It only matters if your startup does well, but if it does, it suddenly matters _a lot_. If you are in talks for an acquisition or funding round five years from now and this topic comes up in due diligence, your company _is over_. It does not matter whether you'd win the legal case -- and you wouldn't -- because there will not even be a legal case. The risk-averse counterparty you'll then be dealing with will nope-nope-NOPE out of that transaction and do business with someone who is capable of minimal levels of professionalism.

Also, while I hate to be the bearer of bad tidings: given that there is no way to untaint the project you are presently working on, I think you're probably better off rm -rf'ing N weeks of work and starting over rather than taking the somewhat accelerated timeframe on a project which has an unfixable timebomb embedded in it.

<comment> barry-cotter As Patrick said you should delete absolutely everything you have written so far, and ideally all evidence that you were working on anything.

If you do a reimplementation it will go much, much faster because you now know what you're doing.

Get a second hand laptop or a Chromebook or something. If you're able to get a job programming you should be able to afford _something_.

</comment></comment><comment><USER3> I'm not familiar with CA law, so I can't comment on whether your employer could lay claim to the intellectual property you create on their hardware. You can probably find that information on the web.

However, there's another obvious risk: if your employer fires you for any reason, they'll demand your laptop back immediately, and you may not get the chance to retrieve anything that's on it (e.g., you may be immediately escorted from the building by security). Anything that's stored on the laptop may fall into your employer's hands at that point.

Also, use of company equipment for personal use may violate your company's own policies, and may give them grounds for firing you. You said you work for a "big corp" \- they frequently have rules like that in their employee handbook.

Do yourself a favor and get your own machine to do your personal stuff on.

</comment><comment><USER4> Joel Spolsky gives a good summary here:

[http://www.brightjourney.com/q/working-company- intellectual-...](http://www.brightjourney.com/q/working-company-intellectual- property-rights-stuff-spare-time)

The key phrase seems to be this one: "These state legislatures usually passed laws that said something like this: Anything you do on your own time, _with your own equipment_ , that is not related to your employer's line of work is yours, even if the contract you signed says otherwise." (emphasis mine)

This suggests doing external work on company equipment might be a bad idea.

</comment><comment><USER5> I am an attorney, but this is not legal advice. Seek licensed counsel in your jurisdiction.

The law basically says that your employer can claim ownership over any work product you make while in their employ (i.e. in the workplace) or using their equipment. So cease immediately if you don't want to potentially forfeit your creation, and use solely your own equipment, outside the usual workplace, to develop it.

</comment><comment><USER6> Rule #1 -- don't be a cheapskate on things which matter.

<comment><USER7> Rule #0: Spend the minimum necessary amount of money.

In this case a used $100-$300 machine is probably the minimum necessary expenditure [as opposed to a new MacBook Pro or it's equivalent].

Implementing a sound backup strategy is more important than any gain in reliability between new and used hardware.

</comment></comment><comment><USER8> Get a computer. Your own computer. This just isn't a lot of money.

A builder needs tools. Get your own tools, build your own stuff. Have no worries. Simple as that.

If anything, owning no other machine does beg the question of how you got it all kicked off, doesn't it?

</comment><comment><USER9> Like others I will say don't do this, however if it's the only PC you have access then why don't you boot up a live Linux DVD or USB distro and do your work in that and save to the cloud?

<comment><USER10> That does nothing to mitigate the risk. It's not just the hard drive that matters -- it's the equipment, which includes the entire PC.

</comment></comment><comment><USER11> Everyone here is pretty much saying, get your own laptop. I'm going to add my voice that sentiment. On practical grounds, you don't want to give your employer any reason to put a checkmark about you on the negative ledger. Even if a lot of people there do it as well, you just want to avoid negative marks, especially at a large corp. On another level, it just feels more like your own work and product when done completely with your own resources. Good luck with the startup.

</comment><comment><USER12> Maybe there are legal implications or company policies, but seriously, how would your employer ever even find out you were using that laptop? Just don't go around advertising it if you do use it, backup your data and wipe it before you return it, you'll be fine.

Of course it might be nicer to have your own laptop that is setup just right for what you're building, but if money is scarce then i would just use the work laptop and keep quiet about it.

<comment><USER13> And if it goes well and the poster is ever asked, under penalty of perjury, what would you advise then?

The cost of a new laptop is fixed and small. The cost of a successful startup being destroyed is potentially massive.

</comment></comment><comment><USER14> Invest in a bottom tier machine. Apart from the healthy separation, it will teach you to value both computation and financial resources.

It's totally possible to code Erlang on a low-end netbook.

The cheap laptop I wrote early self-employed code on was under 20% the price of a cheap Mac and so badly made it was flexible.

The work I produced on it paid for the eventual upgrade.

</comment><comment><USER15> It's not worth the risk. Go out and spend a couple hundred bucks on a Chromebook or something. If you need more computing muscle, use vim on an EC2 instance or something.

I agree with other commenters saying you should dump your current codebase and reimplement from scratch.

</comment><comment><USER16> also: things can get really ugly if your corp. decides to throw post-911 terrorism charges at you. I know of several instances where just using work machine for personal email got that treatment so the corp could get out of paying contract fees.

</comment><comment> alok-g >> FYI: I am in CA and my startup is in no way related to what I work on at my day job.

Note: I am not a lawyer.

"Related to" is a very loosely-defined term. Don't be so sure that your startup is not related to your work at your day job.

</comment><comment><AUTHOR> Thanks for all the replies. I will get a personal computer ASAP.

It wasn't that I couldn't afford it, but its just more convenient to have everything on one computer. Yes, looks dumb now looking back at it...

</comment><comment><USER17> Our professors in my EGR100 class warned us about this, even using the school's computers to work on a non-school related project could give the school possible IP claims.

</comment><comment><USER18> if its about 'a computer'..it can be as low as us$100..whats the problem? [http://www.aliexpress.com/w/wholesale- win-8.1.html?initiativ...](http://www.aliexpress.com/w/wholesale- win-8.1.html?initiative_id=SB_20150426201611&site=glo&groupsort=1&SortType=total_tranpro_desc&shipCountry=sg&SearchText=win+8.1)

</comment><comment><USER19> Depends on what you signed when you started your job. Standard I am not a lawyer disclaimer goes here.

Seriously computers are cheap go buy one.

</comment><comment><USER20> why the hell would anyone do this, or even think about doing this?

if you're doing it for convenience, it ain't worth the jail time.

if you're doing it because your work computer has expensive development software, you're breaking ethics and legal agreements, then you'd deserve the jail time.

if you're doing it for any other reason ,DONT.

</comment><comment><USER21> If you don't have the cash for a computer, you can get one at very little cost, maybe even for free from an electronics recycler. Branham High School in San Jose operates one as a student club; I purchase five decent quality PCs for fifty bucks total.</comment>


Computer Graphics from Scratch (2017) - <AUTHOR> http://www.gabrielgambetta.com/computer-graphics-from-scratch/ <comment><USER2> Like many other programmers, I originally picked up programming because I wanted to write games. I spent time on my own in high school messing around with rudimentary 2D libraries in C++. That feeling of awe and accomplishment that was captured the first time an image successfully moves across the screen was what got me hooked.

After starting college I soon learned of the trials and tribulations of software engineers in the gaming industry. I changed my degree to Computer Engineering, took the embedded track, and recaptured that sense of awe by staring into the abyss of an Oscilloscope. Albeit, I did still take several graphics courses as electives (simply because I loved the subject).

<comment><USER3> Seems like many people start and end this way. Games are a great motivation to learn how to code. But once you do, you find that other subfields of CS are more interesting and useful. And you just get older. :)

But that is not reason to quit game development entirely. It is still a good hobby that makes you a much better programmer, because it touches so many areas of CS and math. 3d graphics, state machines, trees/graphs, pathfinding, multithreading, memory management, vector math, networking etc.

<comment><USER4> > But once you do, you find that other subfields of CS are more interesting > and useful. And you just get older. :)

It is true that some people, as they get older, claim to find games less interesting. In my opinion, some of them simply jaded a bit, and would be a good thing for them if they tried to find enjoyment again in the small things. I know, because I was there too. It depends a lot on the culture.

There are also others that start claiming games are useless, immature and that the world will end if youngsters keep playing them.

Entertainment has been useful even before civilization existed, and those that enjoy the time to entertain themselves, do; even if it is in the form of working on dream projects. Yes, that is playing too.

As for your other point, there are objectively very few (if any) topics as interesting as games for CS people, given the so many areas of CS (and non-CS) they encompass at the same time. Hardly any other area of work touches so many domains. Only operating systems, browsers and CAD apps (and maybe Emacs ;) are close as vast.

<comment><USER5> Interesting is very subjective term. E.g. some find theory much more interesting than games

<comment><USER4> What do you mean by theory?

</comment></comment></comment></comment></comment><comment><USER6> Author here. What a surprise to open HN and see this on the front page :) Happy to answer any questions.

<comment><USER7> Thank you very much for this. I'm glad there still are people writing books like this one. When I was a teenager, I found a book by L. Ammeraal which was awesome reading. It taught how to build a simple 3D graphics renderer with hidden edges removal and other interesting features. Unfortunately, back then I was a Pascal fan, so it took me some significant effort to translate bits of the code from the book from C

Later, I found another book, can't remember the author, which described even more things, like z-buffering and so on. Very interesting and very useful.

<comment><USER8> [http://www.opengl-tutorial.org/](http://www.opengl-tutorial.org/) is a pretty fantastic resource of learning this stuff.

Don't worry too much about opengl vs direct x vs vulkan. There are underlying principles that apply broadly to both.

Alternatively if you want a book that goes more in depth, but still allows you to take your first steps, opengl programming guide 8th+ edition is good.

Expect it to require some patience no matter what route you take. Graphics programming is finnicky.

</comment></comment></comment><comment><USER9> This is awesome! One thing I really appreciate is building up the mathematical concepts. For example, instead of providing a ray-sphere intersection formula, the tutorial talks about representing a ray and a sphere, and how the two representations must match at intersection points.

When I was asked to teach a workshop on computer graphics, I wanted to make the concepts accessible to those who were either rusty, or hadn't even encountered the necessary math. Given a limited amount of teaching time, I introduced only the most relevant math, but did so from first principles. Hopefully my treatment can be useful to others: [https://avik- das.github.io/build-your-own-raytracer](https://avik-das.github.io/build-your- own-raytracer)

</comment><comment><USER10> I found it surprisingly hard to get access to the primitives mentioned in the intro, on a modern pc. How does one draw a pixel on a specific coordinate in a modern OS?

<comment><USER11> the best/easiest way is still use opengl/directx/etc but draw your texture in software, and then draw the texture full screen.

This is the approach I used to teach software rendering in gameswithgo.org we make a putpixel function as in the old days, and use it to build up a texture, which we draw each frame. The texture becomes what used to be the framebuffer.

<comment><USER12> Copying the entire framebuffer over the PCI bus makes me sad, though it's obviously way faster than when you could memory-map the framebuffer. These days you can't map texture objects in memory because texture storage on GPUs is its own black magic and textures are not stored as simple linear framebuffers. It would be fun to restrict yourself to a well-documented architecture, e.g. give everyone a cheap intel-based notebook and write out commands directly for the graphics chip. I guess while fun that would teach more about doing low-level hardware access than graphics themselves.

And while on the topic of changing hardware forcing us to change our algorithms, I wonder if teaching scanline rendering is even worth it these days. Every CPU supports SIMD and a SIMD-optimised software rasteriser is a very different beast than the classic scanline triangle rasterisers of old.

Probably the fastest software rasteriser for modern CPUs is OpenSWR [0], written by Intel mostly to keep themselves relevant in the data visualisation space until GPUs eat HPCs (GPUs still can't help you when your dataset is measured in hundreds of gigabytes of graphics data), but it scales perfectly fine down to desktop CPUs. The code for it is in the Mesa tree [1]. I wish I could explain exactly how it works, but it's a pretty big beast and I haven't had the time to read and understand all of it. Intel gave a presentation on it at the HPC developers conference back in 2015 [2]

[0] [http://openswr.org/index.html](http://openswr.org/index.html)

[1] [https://cgit.freedesktop.org/mesa/mesa/tree/src/gallium/driv...](https://cgit.freedesktop.org/mesa/mesa/tree/src/gallium/drivers/swr/rasterizer/core)

[2] [https://youtu.be/gpYd18E3TWc?t=1531](https://youtu.be/gpYd18E3TWc?t=1531)

</comment></comment></comment><comment><USER13> Yes, it is very rewarding to program your own graphics routines or your own simple implementation of a raytracer and then see the correctly rendered scene on screen for the first time.

I did this on my Amiga a lot time ago (1995), and then re-created the feeling using ShaderToy: [https://www.shadertoy.com/view/lds3z8](https://www.shadertoy.com/view/lds3z8)

It's so cool: A scene that took 10 minutes to render in 1995 - nowadays you can see that scene through a moving camera raytraced in real time in your browser!

</comment><comment><USER14> Anyone know how this guide compares to tinyrenderer?

[https://github.com/ssloy/tinyrenderer/wiki/Lesson-0:-getting...](https://github.com/ssloy/tinyrenderer/wiki/Lesson-0:-getting- started)

</comment><comment><USER15> Graphics was one of the hardest courses when I was in school for game development. We started with raytracing, did rasterization from scratch, then worked with DirectX and OpenGL. I formed lifelong friendships struggling through toon shading, bump mapping, and particles with HLSL shaders.

</comment><comment><USER16> This ought to be super helpful for my toy rasterizer project written in Rust.

If anyone is interested, I'll post the link (it's crappy)

I suggest everyone to try implementing a rasterizer in a new language; it goes over a lot of language fundamentals and a lot of reasonably efficient memory manipulation (if you try to, at least) is required, which forces you to be intimate with the lang. Great Rust practice for me, at least.

</comment><comment><USER17> Any dummies guide to shaders?

<comment><USER18> [https://thebookofshaders.com/](https://thebookofshaders.com/)

</comment></comment><comment><USER19> The capitalization of Scratch in the title made me first guess that they were using the educational programming language Scratch.

<comment><USER6> This is the capitalisation the OP used; the one I use myself is lowercase. Perhaps a mod (paging dang?) could fix this?

</comment></comment><comment><USER20> This is primitive, but not quite from scratch - that makes me think of TempleOS. This is more like, computer graphics without libraries.

<comment><USER6> Fair enough. It's definitely "from scratch" compared with most graphics courses which start at the OpenGL level, but as with whether a language is "low level", it's somewhat subjective.</comment></comment>


File Uploading without a Server - <AUTHOR> http://kvz.io/blog/2013/09/03/file-uploading-without-serverside-code/ <comment><USER2> > However with services like Disqus, and (my own startup) Transloadit, it gets > more and more feasible to just run a flat site and have external services > cover for not running serverside code and a database yourself.

It's funny how the more things change, the more they stay the same. I remember in the beginning of the web, when we all used externally hosted "guestbook" scripts and visitor counters. It seems we're back there again...

<comment><USER3> People were all supposed to have their own personal home pages by now. Instead, we're too busy screwing around on Facebook...

</comment></comment><comment><USER4> No, there is no use case where this is feasible on the public web. Even a small site with a strange URL and few visitors will be attacked in exactly the way described in the blog post if they try to use this. I'm sure some bot maintainers are already pushing for a detection of this enormous security hole.

Do not do this.

<comment><USER5> There's lot of possibilities there; the demo page returns a tmp url that will work for a while with the data transfered, so you could use the service to distribute files in parts of 30MB max...

<comment><USER4> Yes, _anyone_ can use your site to host any file on your server.</comment></comment></comment>


Campaign to save collection of rare Alan Turing papers ends in success - <AUTHOR> http://www.thinq.co.uk/2011/2/25/turing-papers-safe-last-bletchley-park/

<comment><USER2> Did anyone else notice how Google is referred to as "advertising giant Google", not "search engine Google" ? An accurate, but unconventional, portrayal.

</comment><comment><USER3> What I'm wondering is who is attempting to sell the papers?

From the article:

 _The collection, now officially named the Turing-Maxwell Collaboration Collection, comprises the largest known collection of Turing's offprints in the world - given by Turing to his close friend and colleague Professor Maxwell Newman._

Wikipedia says that Newman passed away in 1984: <http://en.wikipedia.org/wiki/Maxwell_Newman>

Is the current owner one of his heirs or some other party?

</comment><comment><USER4> These are off-prints of published papers, not his original notes - so why don't I just go top the library stacks and photocopy the original journal ?

<comment><USER5> "The papers are thought to be of particular historical value as much of Turing's war-time work was destroyed under the Official Secrets Act and the man himself kept few personal possessions."

<comment><USER4> Yes - thats the point, all the interesting stuff - the notes on enigma and the invention of the computer are gone. All we have are a bunch of preprints from the 30s - but these are preprints of journals that do exist

(note to those under 50 : upto to the 1980s journals would send you a few dozen unbound copies of your paper for you to distribute - before photocopiers were common)</comment></comment></comment>


Why You Should Use Rule-Based Passwords - <AUTHOR> http://thekeesh.com/2013/01/why-you-should-use-rule-based-passwords/

<comment><USER2> The idea must be in the ether! I just spent the last two days obsessed with this, having decided to make another stab at Bitcoin.

I now have a neat method worked out that I can do on the fly in my head, and a little Python script to check it.

Sorry I don't feel like sharing any actual tricks/code, but here are a few examples. Whatever the site address, it spits out a password from 13 to 20 characters in length. If anyone can explain my algorythm, I might even send you a Bitcoin!

<https://news.ycombinator.com> -> 0$$onew$vwqitt&10

<http://slashdot.org> -> 4$$guola$fwqivt&13

<http://arstechnica.com> -> 25$bars$jwdibt&15

<http://www.theverge.com> -> 4$$gthe$twggt&11

<http://www.ibm.com> -> 49$tibm$jwcint&17

<http://www.wired.com> -> 81$fwir$swfid&18</comment>


Ask HN: Anyone just feel that earthquake?  - <AUTHOR>

I'm in SanFran. First one! <comment><USER2> Looks like a 4.6 - [http://earthquake.usgs.gov/eqcenter/recenteqsus/Quakes/nc402...](http://earthquake.usgs.gov/eqcenter/recenteqsus/Quakes/nc40234037.php)

</comment><comment><USER3> Yes: <http://www.twitscoop.com/>

<comment><AUTHOR> That is really interesting. It's fascinating to see the common words people use to describe it (besides earthquake):

felt feeling shaking experienced else(I'm guessing this was "anyone else") etc.

I was home alone at the time so turned immediately to twitter to confirm and less than 1 minute after i felt the quake a page full of people had tweeted it.

How can CNN compete with that?

<comment><USER3> CNN won't compete with it. They'll license it.</comment></comment></comment>


WTF: Bitcoin Cash going up from 1180$ to ~4720$? - <AUTHOR> I sold all my BCH. Is it true that Bitcoin Cash will gain 4x today due to adjustment to Bitcoin rise? Someone told me so I am wondering. WTF? <comment><USER2> There is so much wrong with this.

Do you think HN knows the future (or anyone does for that matter)? Flattering if so, but nonsense.

You say you sold all of your BCH, but hearing one person say it will go up makes you want it back? You are gambling with stuff you don't understand and doing it based on rumors.

</comment><comment><USER3> If you believe just buy them back. Your guess is as good as anyone else's</comment>


What is the worst software bug in history? - <AUTHOR> http://programmers.stackexchange.com/q/40477/2673

<comment><USER2> Buffer overflows were only very rarely perpetrated by the gets() library function; since the mid-'90s, programs that called gets() would trigger a warning message on the console due to its insecurity. Far more vulnerabilities were caused by sprintf() than were ever caused by gets().

This would be a pedantic comment but for the insinuation that response made that buffer overflows in C/C++ had been somehow mitigated by changes to the C standard library in modern ANSI C. No.

</comment><comment><USER3> If you include _pre_ -history, I would say the one that causes people to see patterns that aren't really there.

<comment><USER4> fuzzy logic ain't perfect

</comment></comment><comment><USER5> <http://en.wikipedia.org/wiki/Therac-25> ?

</comment><comment><USER6> not quite 'the worst' but an interesting story no less - <http://en.wikipedia.org/wiki/Siberian_pipeline_sabotage>

<comment><USER7> Debatable that it counts as a "bug" since the code functioned exactly as designed.

</comment></comment><comment><USER8> Y2K

<comment><USER9> Arguably not a bug, since most systems that would have had Y2K problems were being operated well past the lifetime they had been designed for.</comment></comment>


Airbnb measuring discrepancies in guest acceptance rates [pdf] - <AUTHOR> https://news.airbnb.com/wp-content/uploads/sites/4/2020/06/Project-Lighthouse-Airbnb-2020-06-12.pdf <comment><AUTHOR> You can opt out in your Privacy Settings if you don't want to participate. And though you can change your mind at any time, your first name and profile photo may be used if you don't opt out by August 31, 2020.</comment>


Why I want to stop talking about the "developing" world - <AUTHOR> https://www.gatesnotes.com/Books/Factfulness <comment><USER2> I got a visual on a web page.</comment>


A Simple Web Developer's Guide to Color - <AUTHOR> https://www.smashingmagazine.com/2016/04/web-developer-guide-color/ <comment><USER2> What made colours much easier for me was stating them as hsl values, rather than rgb ones, because that's how we actually think about colours.

For example, I can tell just by looking at it that the HN banner is orange (hue: ~30), fully saturated (sat: ~100%), and neither light nor dark (l: ~50%).

The figures are also easier to fiddle with. Something is too saturated? Decrease saturation. Too bright? Decrease brightness. etc. With an rgb value it's very hard to fiddle with meaningfully.

<comment><USER3> Hue means something to you? Having always worked in RGB, I have laterally no idea that a hue of 30 is orange.

At least with RGB, I can imagine what the mix would be.

<comment><USER4> Hue is a circle mapped to a rainbow.

      0° red
      60° yellow
      120° green
      180° cyan
      240° blue
      300° magenta

You can see your red, green and blue every 120°.

Labelled colour wheel:

[http://codropspz.tympanus.netdna-cdn.com/codrops/wp- content/...](http://codropspz.tympanus.netdna-cdn.com/codrops/wp- content/uploads/2015/01/hsl-color-wheel.png)

<comment><USER5> That's a good way to put it.

Tangential, but does anyone else see movement near center of the color wheel when changing focus away from it? Optical illusions fascinate me. Are certain types categorized?

<comment><USER6> Looks like there are some recognized categories:

>3 Explanation of cognitive illusions > 3.1 Perceptual organization > 3.2 Depth and motion perception > 3.3 Color and brightness constancies > 3.4 Object > 3.5 Future perception

[https://en.wikipedia.org/wiki/Optical_illusion](https://en.wikipedia.org/wiki/Optical_illusion)

</comment></comment></comment></comment></comment><comment><USER7> There is a reason for studying colour theory, and unfortunately sometimes you can make things _too_ simple.

There's nothing wrong in principle with having a bright, highly saturated colour for your brand, but using it as a background for a large area of a web page is risky. It's hard to achieve good contrast for any text you put on top, whether you go light or dark, and on some screens the background alone may become overpowering. It might have been better either to go with a significantly darker shade of blue or to desaturate the main colour for the large background area here.

Using a similarly bright and highly saturated but near-complementary colour as an accent right next to that main colour is another risky move. That sort of combination tends to clash, which is why you're probably getting eye strain looking at the CTA button on the demo page here. I suspect it would be difficult to find an ideal flat button colour based on that red accent once you've chosen the blue background, even if you played with the saturation and brightness. However, putting some sort of separator around the button, such as a border stroke in one of the neutral colours so you don't have the two clashing colours actually touching, would probably limit the damage.

The advice on using slightly colourised neutrals instead of plain greys is good, though.

<comment><USER8> The risk with highly saturated colors is they're more difficult to reproduce accurately in cross-media applications, namely print media.

Grays are easy to reproduce in cross-media applications, in theory. In practice, there's so much variation in displays and print, and human vision is sensitive to achromatic colors, the error is essentially guaranteed and it will be noticeable. So you're almost always better off with colors that aren't achromatic, aren't highly saturated, and aren't memory colors, like skin tones.

</comment></comment><comment><USER9> Before you start using your "unique" and "exotic" RGB color as the primary color for your brand, always make sure it actually has a CMYK/PANTONE equivalent. You'll thank me later.

<comment><USER10> Actually, I'd advice to pick the primary color from a Pantone catalogue, while checking (and testing) its screen (RGB) and print/process (CMYK) versions.

<comment><USER11> How do you say "Pantone"? "Pant One" or "Pan Tone"? Maybe "Pan ton ay"?

<comment><USER10> While speaking English, I say "Pan Tone". But my first language is Portuguese; while speaking Portuguese, I (and I think most natives) say "Pan-tawh-ne".

<comment><USER12> That's interesting. Why do you pronounce the same word differently depending on the language spoken? Since it's a product name I would assume it would be pronounced however it is intended by the owner of the product.

<comment><USER10> Yeah, it is interesting. And it's not only with Pantone. I think it happens when a brand is popular (generally, or within a niche such as Pantone within the design community), we "adopt" the word with local phonetics.

For instance, almost everybody here articulares Microsoft as "Meeh-craw-soft" (just like if it was a Portuguese word). The same happens with initialisms, such as HP (the H is articulated "uh-gah" and the P is something close to `pet` without uttering the final T).

<comment><USER12> Do local TV advertisements do the same?

<comment><USER10> Good question. I think so, but I'll give you the hipster answer (which is also true): I haven't been watching enough TV...

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER13> Not mentioned, but important to also consider: accessibility to colorblind people.

<comment><USER14> What do you think of ReColor for that? [http://animesh.co/portfolio/recolor/](http://animesh.co/portfolio/recolor/)

<comment><USER15> Colorblindness isn't a uniform condition. Best practice is to utilize multiple signifiers (hue, lightness/darkness, iconography, etc)

</comment></comment></comment><comment><USER16> I know that "choosing colors" is everything but simple task, but after reading this article I believe I could do it if I had to (e.g. for personal page, or some low budget, nothing-serious-thing). But don't get too comfortable. For something more serious you need a designer. And also you need pay him to get something good.

<comment><USER17> > And also you need pay him to get something good.

Or her of course!

At higher levels, you actually have designers who specialize in specific topics, e.g. color. I know a visual designer who specialized in color personally (before moving into management), that isn't as crazy as it sounds on bigger projects. Other specializations could be typography/layout, touch, animation, and even sound. This is why the role of a designer/coder scares me so much: there is so much to know just in design!

</comment></comment><comment><USER18> I highly recommend color.adobe.com

<comment><USER19> Thank you for recommending this, I love it!

</comment></comment><comment><USER20> For those a bit more technically minded and looking to choose colors in an optimal way (for things like data visualization, intuitive interfaces, etc.), look into Munsell colors!

I made a quick tool for playing with Munsell colors and explaining how to use them here:

[http://research.kumpf.cc/MunsellForDesigners/](http://research.kumpf.cc/MunsellForDesigners/)

Cheers, Adam

</comment><comment><USER21> One of the first things I learned about in my color theory class was how colors can change how they appear depending what other colors they're next to. In fact, some colors will fight visually when placed next to (or on top of) one another. Saturated versions of red and blue were the first example given for that lesson. And that's exactly what the author ended up with here.

That said, there are some good tips in here for finding colors. I once asked a designer that I worked with and still highly admire, "how do you pick color palettes for things?" His suggestion was to start with a color you wouldn't expect, and then try to match colors to it. (He also recommended palette sites like those mentioned in the article for us beginner color people.) But the pick a color you wouldn't expect advice has worked well for me.

</comment><comment><USER22> I usually have to start with some existing logos/material, this is my first stop: [http://www.pictaculous.com/](http://www.pictaculous.com/)

<comment><USER23> That is quite interesting for other purposes as well! Given a photo, it would allow you to pick a nice frame color or what not.

</comment></comment><comment><USER24> I've written a Sublime Text package to convert RGB colors (hex, RGB, & RGBa) to HSL or HSLa. You can convert selected colors or all colors in a file.

[https://packagecontrol.io/packages/Hex%20to%20HSL%20Color%20...](https://packagecontrol.io/packages/Hex%20to%20HSL%20Color%20Converter)

</comment><comment><USER25> Regarding HSL vs RGB, I find this article a good introduction to HSL: [http://thenewcode.com/61/An-Easy-Guide-To-HSL-Color-In- CSS3](http://thenewcode.com/61/An-Easy-Guide-To-HSL-Color-In-CSS3)

</comment><comment><USER26> This is a good color wheel for prototyping as well: [http://www.getmdl.io/customize/index.html](http://www.getmdl.io/customize/index.html)

<comment><USER27> [http://paletton.com/](http://paletton.com/)

<comment><USER26> That's brilliant.

+1

Thanks for this

</comment></comment></comment><comment><USER28> What about a clever web developer's guide to colour?</comment>


Dcentralized url shortening service base on IPFS - <AUTHOR> http://t.bdaily.club/ <comment><USER2> So these various IPFS services are getting pushed to the front page of HN just because they use IPFS?

Honestly, in most cases I do not see a use for decentralizing. In this case, the shortened URL still depends on a central host (bdaily.club or whatever). Whether the underlying link is stored in a decentralized manner is completely meaningless, because all the links will still be broken once the host is gone.

<comment><USER3> That's the thing though, since it's decentralized you could create a new service, e.g. bdaily.horse, and just change the domain of all the links: the short url paths and full url targets are persevered. Not saying it would be trivial to fix but it's _possible_ , which is a good deal better than today.

</comment></comment><comment><AUTHOR> At present, this version does have some problems and doubts, such as [http://t.bdaily.club/ek5wz](http://t.bdaily.club/ek5wz) This link also jump to the centralized service. If you use the long address of ipfs directly, [https://gateway.ipfs.io/ipfs/QmT2AKLygsgMa6r2AvxiJP31JTqSMMK...](https://gateway.ipfs.io/ipfs/QmT2AKLygsgMa6r2AvxiJP31JTqSMMKCVK4FHKXiTCX3bR), the decentralization problem is solved, but the link is too long. there are some solutions (1) shortening the domain name address (2) with a blockchain (such as IOTA), mapping the short address and the hash address.

This service is just an attempt on IPFS, I hope to have this service inspired, then there will be a more usable, more robust app on IPFS.

</comment><comment><USER4> Can someone please explain to me why this is cool? What are the benefits of using a decentralized url shortening service?

<comment><USER5> And on top of that: what practical applications does a URL shortener have nowadays? There was a time when they were pretty popular for posting links on Twitter, but Twitter made t.co an automatic part of their service in 2010.

<comment><USER6> When you need to publish some huge URL without copy-paste tools (paper, documents, phone call).

</comment></comment></comment><comment><USER7> As far as I know, IPFS is not really decentralized. Some people say it is if others pin your files, but there are no guarantees that anyone will do that. I've worked with startups who asked me to use IPFS and this is what it looks like: setting up an ipfs server to store files on a cloud provider, adding extras for redundancy plus a file backup system. At present it's sufficiently more complex than rolling out S3 + glacier backups with no tangible benefit besides "decentralized" cred

It's possible this will change via Filecoin or others, but at present the term "decentralized" is misused here.

<comment><USER8> I agree but I also disagree. I think there is always a line of confusion between distributed and decentralised.

The Protocol is decentralised, then the users/services can decide how to replicate the files. If everybody will have the same files, it will be 100% distributed.

We can argue that Bitcoin with SPV clients is just decentralised and not distributed as well.

<comment><USER9> I don't agree to that

</comment></comment></comment><comment><USER10> The implementation is neat. But I honestly don't get the point of this site. The shortened URL is of the form [http://t.bdaily.club/34fe6](http://t.bdaily.club/34fe6).

When you open [http://t.bdaily.club/34fe6](http://t.bdaily.club/34fe6) the server redirects you to a file in IPFS which has a javascript script tag to redirect further to the actual URL.

My question?

* What's the point of this service when you can directly redirect to the actual URL instead of redirecting to the IPFS file?

* Users can also alternatively share the IPFS file directly (eg [https://cloudflare-ipfs.com/ipfs/QmfFs8v6hXK258ov9bXGuqzUVsJ...](https://cloudflare-ipfs.com/ipfs/QmfFs8v6hXK258ov9bXGuqzUVsJGRPChviuuUXUY6axTQz)). But the problem is IPFS URL/hash is bigger than the urls itself in most cases. I think the point of URL shortner is to have a small URL. This is more like a URL enlarger service.

* Most importantly someone has to seed the IPFS files so that the links keep working. What's the incentive for the website owners to seed the files for free? There is no guarentee that the URLs will work if someone open it after a month or year.

</comment><comment><USER11> I think it might be a good place to plug my decentralized url shortener (based on ethereum blockchain) [https://0x.now.sh](https://0x.now.sh)</comment>


Ask HN: Facebook developers who miss the old platform forum/wiki? - <AUTHOR>

I know facebook now directs all developers to ask their questions at facebook.stackoverflow.com, but I for one miss the old community of the Facebook forum. It was my primary place to figure out what is happening in the platform, know when something's broken and discuss things beyond programming such as monetization and policies. I believe the stackoverflow section just doesn't fit the purpose as the platform is constantly  moving and questions become obsolete very soon. Plus it would be nice to have a wiki with best practices that developers can update.<p>So I started to post some quickstart recipes that will hopefull make it easier for newbies to get started at http://www.fbdevhub.com/ I am wondering if anyone wants to contribute to the wiki or forum. I plan to post more recipes when i get the time. <comment><AUTHOR> links:

<http://www.fbdevhub.com/wiki>

<http://www.fbdevhub.com></comment>


Ask HN: What is your opinion?  - <AUTHOR>

Is it right for a freelance Web Designer, to use Themes and Templates (ie http://www.woothemes.com/)and then charge a very high price because it is such good work? <comment><USER2> The only problem I could see is if what the freelancer was doing could be described as "reselling" which the original designer probably forbids. But pricing is just something that the buyer and seller work out.

Next time, put your question in the headline.

</comment><comment><USER3> Your not a very good web designer if you are basically reselling other peoples work</comment>