Ask YC: Feedback please - Actual size visualization webapp. - <AUTHOR> http://pective.com/

<comment><USER2> Dude, make this work with online shopping.

This is probably hard since most product shots are perspective, but it would be awesome if I could point to an image at some online store and type in the dimensions and you scaled that photo to actual size.

Here's a product category where it'd be useful (and where the photos are mostly straight on): [http://www.amazon.com/Canon-PowerShot-SD1000-Digital- Optical...](http://www.amazon.com/Canon-PowerShot-SD1000-Digital- Optical/dp/B000NK8EWI/)

<comment><USER3> Extending the online shopping idea a bit, this would be of great use for folks buying jewelry, watches, etc. online.

Let's say you are buying a watch, amazon has images, but those are not actual sizes; although amazon lists the dimensions separately. Having the actual image size would, in my opinion increase sales in this category.

Also, check if you can integrate any of this with like.com.

Good idea, good luck!

</comment></comment><comment><USER4> Can you use the User-Agent string is some intelligent way to guess the screen size instead of asking me to enter it?

Also, might be nice if you had some presets like, say, Macbook, Macbook pro, etc.

<comment><USER5> Maybe the best solution would be to show a scalable picture of some coins, and ask them to hold a coin up to the screen make the image output the real size.

<comment><USER6> I thought of that, but it doesn't internationalize well. A USB plug is probably more universal but a little weird.

</comment></comment></comment><comment><USER7> Haha, I love the concept! I'm not sure how often I'd go back and visit, but it was certainly an amusing little distraction.

<comment><USER8> Agreed, I'd love hear what you used for the back-end in rendering the image sizes.

<comment><AUTHOR> Well, it's essentially Javascript.

It stores the ppi (pixels per inch) of the image, and the ppi of the screen and scales accordingly

</comment></comment></comment><comment><USER6> This is an idea I toyed with but could never bring myself to implement once I realized its most popular probable use. If you want to email (see my profile), I have a suggestion for a domain name that does not involve the word "size" or "big."

Also, forget the "screen size" thing. Just use physical measurements in CSS ("width: 1cm") - it works remarkably well on a variety of browsers.

<comment><USER9> That fails rather dramatically (approximately .7x reality) on my machine.

If it furthers the matter, I'm on a ThinkPad T60p (15" UXGA), XP, Google Chrome (verified in Opera as well)

Pretty cool site, though. I was pleased that the several things I tested were sized as accurately as they were.

</comment></comment><comment><USER10> Heh, this is really cool. But after playing with it a bit, there's not really much to come back to.

You remember that graphic a long time ago that uses to be on the web that showed the relative sizes of different spaceships (like star trek enteprise etc). That was amusing, and if you had something like that regularly coming up, I'd put you in my rss feed. Amuse me.

But otherwise, it's really nicely done, and it does what it is supposed to do properly. I like it.

(Just think of adding some reason why I would want to go back)

<comment><USER6> The real use of this kind of site is for new gadgets. If you can compare things to the size of an iPod, deck of cards, etc. it makes for a nice feature on a news story for an upcoming gizmo.

</comment></comment><comment><USER11> The images never seemed to load for me. But it appears that it creates a scaled version of what you selected based on your monitor size?

Would be helpful to build up a product comparison database, so that I can compare the new cellphone I am thinking about buying to my existing phone to get a real-world idea of the dimensions.

Suggestion for allowing people to catalog their own stuff: create a printable template that I can print out and photograph my object along with a reference item (us dollar, quarter, etc). Between the reference item and the printed grid you should be able to work out the dimensions of the photographed object. You could probably get a massive social effect from people photographing and cataloging their various objects.

<comment><AUTHOR> _The images never seemed to load for me. But it appears that it creates a scaled version of what you selected based on your monitor size?_

Do you have cookies disabled ?

Yes, it does scale based on the monitor size to give you the actual size.

<comment><USER11> No, I have cookies enabled. They finally loaded after a very long wait. Seemed like your site was sending connections to odd places (wikipedia.org, etc).

</comment></comment></comment><comment><USER12> Very interesting site - the interface is very clean and works well.

Nicely done!

Maybe have the threshold for abuse a bit higher (I added the giant cookie and reported it for abuse).

</comment><comment><USER13> The size is way off for me. Tried on my Mac Book Pro's 15" screen and the batteries are huge, a good 50% bigger than real life. I'd imagine you would need to get screen size and DPI to accurately resize the images. Perhaps you could have a sample image (like the AA batteries) along with a slider to allow the user to set the exact ratio.

<comment><AUTHOR> Perhaps you've disabled your screen resolution tracking (screen.width / screen.height).

To calculate the DPI it uses the screen resolution (pixels) and your reported screen size (inches), if either is missing it would fail to work (for now).

<comment><USER13> Safari might not report it, because I haven't changed anything (I wouldn't even know where to change that in Safari). I checked in FireFox and it was much closer to reality.

Update: Safari does report it, so it looks to be another issue. Perhaps a bug in the scaling for Safari?

<comment><AUTHOR> Yes, perhaps it is a bug in Safari. Thanks for the report.

Edit - It might be the way Safari handles onload - <https://bugs.webkit.org/show_bug.cgi?id=13241>

</comment></comment></comment></comment><comment><USER14> Add a 'scale' slider or buttons at the bottom. Then offer this service to companies that want to show pictures of their goods in 'actual size', with the scale used for larger objects.

Perhaps might have some traction in the 'adult entertainment' category.

</comment><comment><USER15> CD was about right, but 360 controller was off by > 2x. "Image" bug, or site bug?

<comment><AUTHOR> It was user submitted, so neither :)

</comment></comment><comment><USER16> Matched my Macbook screen size to a CD by holding a real CD up to the screen. Every other picture is now way off; for instance, credit cards are 1/3 too small, but an Xbox controller is too big to get my hand around.

<comment><AUTHOR> Perhaps you've disabled your screen resolution tracking (screen.width / screen.height).

To calculate the DPI it uses the screen resolution (pixels) and your reported screen size (inches), if either is missing it would fail to work (for now).

<comment><USER16> I can disable that? How do I do that?

<comment><AUTHOR> The Statcounter logs show Unknown resolution for a lot of the machines.

I'm not sure if that can be disabled or not or is system dependent. (I'm assuming every system reports it correctly as of now).

If your system reports the resolution correctly here - [http://andylangton.co.uk/articles/javascript/browser- screen-...](http://andylangton.co.uk/articles/javascript/browser-screen- resolution/) \- then it must be some other bug.

</comment></comment></comment></comment><comment><USER17> I submitted an image of the Hindenburg. The horizontal scaling actually seems to work, but without a vertical scrollbar I can't see the image. (Safari)

</comment><comment><USER18> It's really neat, but your domain name really needs to be thought through....

</comment><comment><USER19> It thinks my 20" LCD is 22". I'm flattered!

<comment><AUTHOR> Do you mean the "Adapted for a XX screen" figure ?

<comment><USER20> Yes. I'm in the same boat. I have a Dell widescreen 20".

</comment></comment></comment><comment><USER21> How will you make money?

<comment><AUTHOR> Not thought through, but an affiliate program (Amazon) might make sense.

</comment></comment><comment><USER22> Monitors with the same diagonal can have vastly different DPI resolution.

Other than that, a very nice website.

<comment><AUTHOR> Of course, it does take into account both physical size (inch) and screen resolution (pixels) to calculate DPI.</comment></comment>


Introducing Duolingo Stories (Beta) - <AUTHOR> https://www.duolingo.com/comment/23206010 <comment><AUTHOR> Stories are currently only available for English speakers learning French, German, Portuguese, and Spanish, but I think they're a really well-done kind of stepping stone from the regular Duolingo courses into a bit more in-context learning. Hopefully they'll keep fleshing it out; it's a really nice addition to their platform.</comment>


Ask HN: On giving up? - <AUTHOR> Hi,
I am a full-time programmer and don't have a degree in CS. I intend to learn Scheme and have been working my way using this book https://www.amazon.com/Concrete-Abstractions-Introduction-Computer-Science/dp/0534952119.
I had a aim to solve all exercises so it was going well until I got stuck in one of the exercises in Chapter 7. I found it non-trivial and though I let the problem cook in the back of my head for more than a month but I couldn't solve it.
Now this is effecting me because a)- I am feeling like giving up on this book, because I wanted to solve all exercises and now it seems I cannot b)- after this book I planned to finish SICP but now I think if I cannot solve this one may be I cannot finish SICP as well c)- and I am also beginning to doubt my abilities as a programmer.
So I need help from people who learned Scheme (using this book or SICP or at MIT) or who are master of their arts---is it okay if you're unable to solve few problems in the book? Should I carry on and finish the book?
Part of me says I should carry on and finish whatever exercises I can solve but it's sort of discouraging that I am unable to solve a problem after a decent industry experience :( <comment><USER2> Sounds like you're suffering from "imposter syndrome". If you've made it to chapter 7, keep going! I'm certain most people wouldn't have made it to chapter 3.

</comment><comment><USER3> took berkeley cs61a one of the ancestral homes of sicp.

it aint easy, and these were bright light 18 year olds.

keep going, skip if you need. look up the answer and learn from it.

but G*d Damn sicp, was it really necessary for one of the first assignments to do newton's approximations of derivatives!!

sheesh, how about a good old tic-tac-toe game ;)

</comment><comment><USER4> Plot twist: the exercise was actually impossible.</comment>


Federal judge stays deportations of travelers in Trump immigration order - <AUTHOR> http://thehill.com/blogs/blog-briefing-room/news/316714-federal-judge-blocks-trump-immigration-ban-nationwide <comment><USER2> The ACLU is also reporting that the stay was granted: [https://twitter.com/dale_e_ho/status/825520404777287680](https://twitter.com/dale_e_ho/status/825520404777287680).

Many of you are probably watching the horror show unfold and wondering what tangible thing you can do. Joining or contributing to the ACLU is one small but important, specific way to help: [https://action.aclu.org/secure/become- freedom-fighter-join-a...](https://action.aclu.org/secure/become-freedom- fighter-join-aclu-7).

[https://twitter.com/seligerj/status/825529092414046208](https://twitter.com/seligerj/status/825529092414046208)

<comment><USER3> Is it possible to anonymously donate to the ACLU?

As a PR in the process of obtaining citizenship, a small fear of mine is that USCIS will start penalizing applicants that support organizations opposed to Trump. Today just proved that anything is possible and I'm sure we've all seen the stories about CBP asking to see the social media feeds of travelers in the past.

<comment><USER4> I'm replicating @nnf's response - never donated till now, figured I'll do $10 monthly, but bumped it to $15 for you.

<comment><USER5> That donation has also been on my to-do list for a few days, you guys just kicked me into pulling the trigger. Replicated.

<comment><USER3> Awesome. Thanks!

</comment></comment></comment></comment></comment><comment><USER6> I'm sorry to report that it's not over yet:

> Stay covers the airport detainees and those currently in transit. Doesn't > change ban going forward. Prev unclear tweet deleted

[https://twitter.com/JessicaHuseman/status/825525603491278848](https://twitter.com/JessicaHuseman/status/825525603491278848)

> Important clarification. This does _not_ prevent Trump admin from blocking > new travelers.

[https://twitter.com/ericgeller/status/825525917602693120](https://twitter.com/ericgeller/status/825525917602693120)

<comment> joatmon-snoo Link to the current stay:

[https://pbs.twimg.com/media/C3TahZ_WEAAzGAK.jpg:large](https://pbs.twimg.com/media/C3TahZ_WEAAzGAK.jpg:large)

EDIT: better link

[https://www.scribd.com/document/337807824/Darweesh-v- Trump](https://www.scribd.com/document/337807824/Darweesh-v-Trump)

<comment><USER7> [https://www.aclu.org/news/federal-court-grants-stay- challeng...](https://www.aclu.org/news/federal-court-grants-stay-challenge- trump-immigration-ban)

</comment></comment></comment><comment><USER8> No one seems to be talking about that fact that Trump can do these things because the Congress has specifically authorized the president to do so. It seems as though a massive amount of power in one person's hands is OK is some situations but not in others, depending on one's political persuasion.

And the list of countries is from Homeland Security's list of "countries of concern" compiled during the Obama administration. _And signed into law by Obama himself._

[https://sethfrantzman.com/2017/01/28/obamas- administration-m...](https://sethfrantzman.com/2017/01/28/obamas- administration-made-the-muslim-ban-possible-and-the-media-wont-tell-you/)

Of course some will blast me as supporting Trump or supporting this ban. Not true.

<comment><USER9> I'm an Iraqi Canadian with a Muslim name, so I know a little more than the average person about this issue.

I can tell you that what Trump is doing is unequivocally worse than what Obama did. One of the things Obama did when he became president was make it easier for nationals of several Arab countries (including Iraq) to travel into the United States.

After the 9/11 attacks, the Bush administration required travellers from a number of Arab countries to disclose their travel plans at entry. It also placed limitations on their movement within the US. Obama and the Democrats waived that requirement. Unfortunately I can't remember the name of this law, and I couldn't find it now. If you can find it and comment with the name, I'd greatly appreciate it. (see update below)

What Obama did in 2015 might have been negative for Arabs who come from the nations affected, but he still left the process better than he had received it.

Also, he didn't campaign on banning Muslims from entering the US, didn't thoughtlessly keep out Green Card holders and dual citizens, didn't say "Islam doesn't like us".

There is no comparison between Obama and Trump.

Edit: it was NSEERS. [https://en.wikipedia.org/wiki/National_Security_Entry- Exit_R...](https://en.wikipedia.org/wiki/National_Security_Entry- Exit_Registration_System)

I should point out I'm not criticizing your opinion, which is entirely valid. Just pointing out how I see it myself.

<comment><USER10> 6 of the 7 countries facing a temporary ban, are happy to enforce a permanent ban on Israeli Jews from entering their lands.

<comment><USER11> well thank goodness we don't penalize innocent individuals for the abhorrent laws of their nation's governments - especially when many of those people come from nations in which the people have no say and no control over their government and its actions.

</comment></comment></comment></comment><comment><USER12> CNN is reporting that the White House over ruled the DHS when it came to green cards.

>Friday night, DHS arrived at the legal interpretation that the executive order restrictions applying to seven countries -- Iran, Iraq, Libya, Somalia, Syria, Sudan and Yemen -- did not apply to people who with lawful permanent residence, generally referred to as green card holders. The White House overruled that guidance overnight, according to officials familiar with the rollout. That order came from the President's inner circle, led by Stephen Miller and Steve Bannon. Their decision held that, on a case by case basis, DHS could allow green card holders to enter the US.

<comment><USER13> I've seen a few references to this applying to people with dual citizenship too - is that true or is this only effecting permanent residents?

<comment><USER14> Dual citizenship with one of the listed countries and another country (including close allies like UK and Canada), not dual citizenship with the US.

<comment><USER13> Ah okay, that makes much more sense.

</comment></comment></comment></comment><comment><USER15> FYI, Chris Sacca is matching grants to ALCU up to $150K...

[https://twitter.com/sacca/status/825475296614707200](https://twitter.com/sacca/status/825475296614707200)

</comment><comment><USER16> A little OT, I guess, but the WaPo's story about this repeats a map I've seen that shows the seven countries.

Conspicuously absent are Egypt, Saudi Arabia, UAE and Lebanon, which is where the people who hijacked the 9/11 planes, the worst, and most logistically complex, terrorist act against the US ever, were from. Where's the logic? [https://en.wikipedia.org/wiki/September_11_attacks#FBI](https://en.wikipedia.org/wiki/September_11_attacks#FBI)

I don't at all think that this order should be in effect, but I don't see the logic in its implementation.

<comment><USER17> Not that I agree with the EO, but the logic behind it was that 6 of those 7 countries have ongoing insurgencies involving the IS, and Iran was dragged in there due to either existing prejudice or more likely their involvement in Syria and Iraq.

If this was entirely driven by religion they'd better put Bosnia and Albania on the list too.

<comment><USER18> Albania is actually mostly atheist/agnostic country. It has three religions on paper but most people are not religious at all. It is a staunch US ally and part of NATO as well.

That logic doesn't hold water. If the rule was banning any country that has any muslims then it would ban 98% of European countries, as all have a %percentage of practicing muslims.

This rule seems more like a childish fit, to appease to the base voter that voted out of fear of muslims in general.

<comment><USER16> Yeah, there was an article on HN today from a Venezuelan writer (which HN flagged away ...) describing Chavez's and Trump's tactic, which is to paint a group with the bad guy label, and whip people up to hate that group, and in turn love the guy who says only he can save them.

</comment></comment></comment></comment><comment><USER19> I personally support the executive order in its motif.

Radicalization of US-born or US-admitted Muslims by clerics, relatives, social media -- is real, eg [1] (Fort-hood terrorist), San-Bernardino terrorists [2].

Therefore, the argument could not just be about questioning if any visa/green card holder for the initial list of 7 'banned-county -->to--> Muslim terrorist perpetrating killing on US soil'.

It is a preventive measure, _with a time limit_ . Very appropriate for this period of time, given the war with ISIS.

I am not, however, impressed with the execution or the preparation that went into this particular order. I would like to see a different level of scrutiny and reduced personal inconvenience afforded to US green card holders.

Appreciate that majority on this forum, including highly respected scientists, will disagree with me. But please allow the expression of, at-least partially informed dissent.

[1] [http://www.washingtonpost.com/wp- dyn/content/article/2009/12...](http://www.washingtonpost.com/wp- dyn/content/article/2009/12/09/AR2009120904422.html)

[2] [https://en.wikipedia.org/wiki/Rizwan_Farook_and_Tashfeen_Mal...](https://en.wikipedia.org/wiki/Rizwan_Farook_and_Tashfeen_Malik#Marriage_and_entry_into_United_States)

<comment><USER20> All squares are rectangles, but not all rectangles are squares.

<comment><USER21> Not all terrorists are muslims, just a majority of them in our current time. This is due to the destabilization of the region more than their religion, although the more radical versions of the religion certainly play a part. Similar things occured in Ireland back in the day: terrorism created by destabilization and fueled by radical religious zeal.

Edit: my auto correct sucks

<comment><USER22> > Not all terrorists are muslims, just a majority of them in our current time

In terms of terrorism in the US, that's not actually true by most counts. The US has seen more far-right terrorists than radical Islamic terrorists. Casualty counts for the Islamic terrorists are typically higher, but there are both more events and more individuals involved in far-right terrorism.

It's still worth noting that in terms of actual risk-per-individual both are astonishingly rare, and if your goal is to save lives that might otherwise be lost to violence there are far, far better ways of doing it.

</comment></comment></comment></comment><comment><USER23> This is an embarrassment.

Even if you completely agree with what the order does, it's impossible to claim that the implementation of this was anything other than a complete and utter disaster. No warning, no clear way to enforce the order, widespread protest, and getting the courts involved within 24 hours.

This is going to have ramifications for years to come. We want to encourage the world's best and brightest to come here, and a precedent of unannounced, widespread, severe changes to enforcement of the laws will cause people to reconsider.

This is utter negligence and I'm ashamed of my country.

</comment><comment><USER24> I think the title of this post is wrong. Here's another post - [http://www.theverge.com/2017/1/28/14427086/federal-court- hal...](http://www.theverge.com/2017/1/28/14427086/federal-court-halts-trumps- immigration-ban) \- that states that "The court specifically ruled on Darweesh and Alshawi's petition; the ACLU will have to include all other similarly- affected immigrants as part of a class action to have it apply more broadly."

<comment><AUTHOR> I think it's fairly unclear for the moment. Some ACLU affiliated account twittered "stay is national": [https://twitter.com/dale_e_ho/status/825521534383095809](https://twitter.com/dale_e_ho/status/825521534383095809)

<comment><USER25> The wording of the ruling looks like it applies nationally to me:

"WHEREFORE, IT IS HEREBY ORDERED that the respondents, their officers, agents, servants, employees, attorneys, and all members and persons acting in concert or participation with than, from the date of this Order, are

ENJOINED AND RESTRAINED from, in any manner or by any means, removing individuals with refugee applications approved by U.S. Citizenship and Immigration Services as part of the U.S. Refugee Admissions Program, holders of valid immigrant and non-immigrant visas, and other individuals from Iraq, Syria, Iran, Sudan, Libya, Somalia, and Yemen legally authorized to enter the United States."

</comment></comment></comment><comment><USER26> Trump and the Republican Congress are going to appoint many judges during his term, including Supreme Court judges. That could be Trump's most enduring legacy.

<comment><USER27> Unless the dems block all those nominnees. If they do, we could actually see some bipartisan work to appoint moderates.

<comment><USER28> Given the Republican commitment to popular bipartisan work over the last eight years, I wouldn't hold my breath.

<comment><USER27> I'm not even holding my breath for the dems to put up a fight :/

<comment><USER29> When Democracts decided to vote "yes" on some of the more ridiculous appointments, even though they would have been appointed even if those Democrats voted no, it was done for them. I can't take a single thing a Democrat congressman says seriously when opposing Trump if they couldn't even say no to Ben Carson being appointed as HUD secretary.

Grow a spine. What do they even stand for these days?

<comment><USER14> This article speaks directly to your point: [http://www.vox.com/policy-and- politics/2017/1/27/14397448/de...](http://www.vox.com/policy-and- politics/2017/1/27/14397448/democrats-trump-cabinet)

Basically, the standard practice used to be for most cabinet appointments to be easily confirmed with bipartisan support. Obama's appointments saw unprecedented levels of push-back from republicans, but still received significant numbers of republican votes. Democratic opposition to Trump's nominations has been, again, unprecedented.

My opinion: perhaps, given the fact that their votes are purely symbolic anyway, some democrats are choosing to 'pick their battles', and vote yes to the picks they feel are halfway reasonable, saving opposition for the cases where (again, in their opinions) it matters most.

</comment></comment></comment></comment></comment></comment><comment><USER30> More precisely, it only blocks part of Trump's order:

"Judge Ann Donnelly of the US District Court in Brooklyn granted a request from the ACLU to stay deportations of those detained on entry to the United States following President Trump's executive order."

[https://www.washingtonpost.com/local/social- issues/refugees-...](https://www.washingtonpost.com/local/social- issues/refugees-detained-at-us-airports-challenge-trumps-executive- order/2017/01/28/e69501a2-e562-11e6-a547-5fb9411d332c_story.html)

</comment><comment><USER31> The text of Trump's temporary order is mostly copy-pasted from temporary orders enacted by Obama that have withstood scrutiny, so I wouldn't get hopes up for a full reversal.

<comment><USER32> It's quite telling that when Obama had summarily banned Iraqi refugees for 6 months in 2011 we have heard nary a peep from the press.

<comment><USER33> Trump is banning visa and Green Card holders from returning to the States. This is notably different.

<comment><USER34> Yeah, but Obama also bombed their countries first, which is notably worse.

As a foreigner, for me this looks like a hypocrisy theater of crocodile tears. But then again, this is par for the course for politics in general, and US politics in particular.

<comment><USER35> That bombing was extensively reported and widely criticized.

This attempt to dismiss complaints as hypocrisy is really tiresome. Obama bombed some countries so who cares if Trump fucks over law-abiding American residents for no reason.

Also, I'm fairly sure Obama didn't bomb Iran.

<comment><USER34> > _That bombing was extensively reported and widely criticized._

Really? Did taxi drivers stop serving the airport? Company leaders asking others to "take a stand"? Liberal media unanimous against it? Judicial intervention?

Because it seems this has 10x or 100x the scale those "widely criticisms" of the bombings had under Obama (during Bush, and for the Iraq war it was only slightly better).

> _This attempt to dismiss complaints as hypocrisy is really tiresome. Obama > bombed some countries so who cares if Trump fucks over law-abiding American > residents for no reason._

Well, that's the hypocrisy though. What's worth protesting "law-abiding American residents" who are denied entrance is not for non-Americans from the same countries who are bombed.

Is the world tiring US with all these demands for consistency?

It's like that Mel Brooks quote: "Tragedy is when I cut my finger. Comedy is when you fall into an open sewer and die."

> _Also, I 'm fairly sure Obama didn't bomb Iran._

No (though Bush did several covert military action and internal meddling there), but he did the same thing Trump did:

"The State Department stopped processing Iraq refugees for six months in 2011, federal officials told ABC News [in 2013] – even for many who had heroically helped U.S. forces as interpreters and intelligence assets."

<comment><USER35> Why do people keep bringing up this Iraq refugee thing as if it were equivalent? I'm not going to defend that action, but it's not at all the same. Screwing with legal US residents is a whole different level.

</comment></comment></comment></comment></comment></comment></comment><comment><USER36> Docket: [https://www.plainsite.org/dockets/33xszihl6/new-york- eastern...](https://www.plainsite.org/dockets/33xszihl6/new-york-eastern- district-court/darweesh--et-al/)

Order PDF: [https://www.plainsite.org/dockets/download.html?id=242131326...](https://www.plainsite.org/dockets/download.html?id=242131326&z=4584f490)

Related Cases: [https://www.plainsite.org/tags/trump-muslim-immigration- ban-...](https://www.plainsite.org/tags/trump-muslim-immigration-ban- executive-order/)

</comment><comment><USER37> > "IT IS FURTHER ORDERED that to assure compliance with the Court's order, the > Court directs service of this Order upon the United States Marshal for the > Eastern District of New York, and further directs the United States Marshals > Service to take those actions deemed necessary to enforce the provisions and > prohibitions set for in this order."

Is the U.S. Marshals Service part of the judicial or executive branch?

(Source: [https://www.aclu.org/legal-document/darweesh-v-trump- decisio...](https://www.aclu.org/legal-document/darweesh-v-trump-decision-and- order?redirect=legal-document/darweesh-v-trump-order))

<comment><USER38> Executive. It is part of the Department of Justice.

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

<comment><USER39> Its in a weird situation where it is technically part of the DOJ, but its primary statutory duty is to carry out the orders of the judicial branch: 28 U.S.C. § 566.

<comment><USER40> It's part of the power separation. Congress makes laws, can impeach the executive, and confirms judges, judiciary interprets laws, orders, and constitution, executive nominates judges, vetoes or signs laws, and enforces them.

</comment></comment></comment></comment><comment><USER41> Please donate to the ACLU

<comment><USER42> Joined today!

</comment></comment><comment><USER43> I was at the solidarity rally at the Dulles International Airport in Herndon, VA for a few hours, although I had left by the time this story broke. I'd wonder if it got announced to the crowd.

</comment><comment><USER44> Donated to the ACLU for the first time today. I also plan to call my representative on Monday.

</comment><comment><USER45> I hope this is true. At least we still have a (mostly) independent judiciary.

<comment><USER46> No, you don't.

<comment><USER47> Based on what?

</comment></comment></comment><comment><USER48> What is the authority chain usually here. Can a Federal judge block other such executive orders? Is this used often

<comment><USER40> The USA has clear separation and balance of powers, and the judiciary gets to rule on matters of law and constitution interpretation, so ya. It's like Rock Paper Scissors.

</comment></comment><comment><USER49> For the people who support the ban: do you realise it was catching people in transit, who had no intention of staying in the US?

Here's one woman who was flying from Costa Rica to Scotland. Her initial flight transited through the US, where she was told her transit visa was no longer valid.

[http://www.bbc.co.uk/news/uk-scotland-glasgow- west-38788116](http://www.bbc.co.uk/news/uk-scotland-glasgow-west-38788116)

</comment><comment><USER50> And the DHS has responded to this ruling already: [https://www.dhs.gov/news/2017/01/29/department-homeland- secu...](https://www.dhs.gov/news/2017/01/29/department-homeland-security- response-recent-litigation#)

 _No foreign national in a foreign land, without ties to the United States, has any unfettered right to demand entry into the United States or to demand immigration benefits in the United States._

<comment><USER51> What do we do when the executive branch starts ignoring the orders of the judiciary?

<comment><USER52> It's Congress' responsibility to impeach him.

</comment></comment></comment><comment><USER53> While many Trump stories should be flagged, some are important for society and for HN to discuss.

This is one of those important stories. Americans can not stick their heads in the sand about these anti-muslim actions.

Please do not delete this story. The American and global tech community needs to discuss this. Trump and his advisors win when HN deletes stories like this.

<comment><USER54> I feel alone on this board in thinking this. While I believe the execution of the order was clumsy (why ban green card holders who have already made a life for themselves here and people already mid-flight?), the people of any nation have the right to self determination and have to have complete control over who comes into their country. Trump did not hide his intentions about what he was going to do once in office. He said it loudly and repeatedly. And he still got roughly half the votes.

<comment><USER55> Two issues:

Regarding the specific cases currently making the news, I believe there's a competing argument that people should have the assurance that their personal relation with the government is governed by a set of predictable rules and not subject to sudden and dramatic changes. That would include that any administration is in some way bound by the commitments of their predecessors. To use a less controversial example: If I painted the walls in the white house, finishing 10 minutes before Trump was sworn in, should the new administration be required to pay me?

Secondly, there are limits to the power of the majority, even in a democracy: "Democracy isn't two wolves and a sheep voting on what's for dinner". These limits are defined by the constitution. The bill of rights for individual rights, and much of the rest for the mechanisms of government. That's why Trump won't be God-Emperor His Trumpitrump the First, even though he could probably get the electoral college votes for it.

That may seem somewhat unconstitutional, and it requires a definition of "democracy" that is far more complicated than majority-rule, which is sometimes called "the tyranny of the majority".

<comment><USER54> I agree with you. I wonder if Trump did this in the most inflammatory way he could manage on purpose.

</comment></comment></comment></comment><comment><USER12> So Tump ignores the court and we have a constitutional crisis.

<comment><USER56> Let's wait for that to happen. Seriously, if this occurs (and we are all damn well aware Trump is capable of it), this will approach a whole new level of madness.

<comment><USER57> Some part of me wants Trump to make this mistake, and make more big mistakes of the non-lethal variety quickly so that there is grounds to impeach him before he starts a war.

<comment><USER47> You are more optimistic than I am about the prospect of a GOP-controlled congress impeaching a GOP president.

I think they would only do so if he did something that was obvious to everyone to be a serious existential threat to the US's existence as a country.

I mean, it'd have to be something even more beyond the pale than ignoring the Constitution and transforming the US government into an authoritarian regime without the rule of law. Like, nuking China for no reason, or something.

<comment><USER58> According to Robert Reich[0], the republicans' whole plan is to use trump to ram through their unpopular agenda and then impeach him when he's no longer useful:

Him: They'll get as much as they want – tax cuts galore, deregulation, military buildup, slash all those poverty programs, and then get to work on Social Security and Medicare – and blame him. And he's such a fool he'll want to take credit for everything. Me: And then what? Him (laughing): They like Pence. Me: What do you mean? Him: Pence is their guy. They all think Trump is out of his mind. Him: So the moment Trump does something really dumb – steps over the line – violates the law in a big stupid clumsy way … and you know he will ... Me: They impeach him? Him: You bet. They pull the trigger.

[0][https://www.facebook.com/RBReich/posts/1445206565491935](https://www.facebook.com/RBReich/posts/1445206565491935)

</comment></comment></comment></comment></comment><comment><USER59> Does anybody have experience with the logistics involved in organizing strangers against such actions?

<comment><USER60> From what I've read, most of today's protests have been ad hoc. Most just famous or political people saying "Show up at JFK" or "Show up at LAX".

The fact that so many people gathered (at so many airports) without any kind of major force behind them shows that this order was clearly misguided.

</comment></comment><comment><USER61> If the ban goes to the Supreme Court and is struck down because Trump didn't wait to fill the vacancy with a loyalist first, he'll have essentially failed the marshmallow test.

[https://pbs.twimg.com/media/C2V-XWcVIAAoel4.jpg](https://pbs.twimg.com/media/C2V-XWcVIAAoel4.jpg)

<comment><USER62> Contrary to (common?) belief, I'm not convinced that someone like Scalia would have let the ban stay.

<comment><USER63> Yeah, Scalia was certainly conservative and had some literal-genie interpretations of the Constitution, but he wasn't exactly a lapdog. It seemed like he had a fairly libertarian interpretation of the first amendment and probably wouldn't have approved of thinly veiled religious discrimination.

<comment><USER39> Although not relevant here, Scalia and Stevens dissented in _Hamdi v. Rumsfeld_. The majority issued a weak sauce opinion that admitted the possibility of detaining a U.S. citizen with some due process short of a trial under some circumstances. Scalia and Stevens pointed out that the government must try a US citizen in regular court unless it suspends habeus corpus.

</comment></comment></comment></comment><comment><USER64> Wow, it seems like US is a 24-hour reality show now.

<comment><USER65> What do you expect when a reality tv star is elected president?

<comment><USER66> We fucked up. We got too confident and comfortable. For one, I'm sorry. There's a lot of other Americans out here for think and feel the same way.

To everybody that warned us about Trump, We cannot express to you how regretful we are. We've really got a lot to make up for.

</comment></comment></comment><comment><USER67> I'd like to know why anyone thinks America owes anyone anything?

The ban is absolutely necessary. You Americans have a great country but you're going to ruin it if you don't take your time to listen to Trump.

There is no way that unchecked immigration is a good thing for any country in the world let alone America.

I've heard what has been said about how immigration made America what it is today - great. However, immigration should be based on whether the immigrant will add value to your country. If an immigrant is coming to set up a business, do further studies and other positive things like that, then by all means provide them with a way to come in.

However, if there's a threat of terrorism from the immigrant or if they aren't adding value but will instead be recipients of welfare all I can ask is, WHAT THE HELL IS GOING ON?

How can you sustain this? You cannot save everyone in the world. You just can't. The best you can do is help them from a camp in their own country and even then, it's your choice as a country that has fair elections.

Why did you even have these elections if you're going to disallow the president that you yourselves chose in FAIR elections to do his jobs. Is there anything new that Trump is doing that he did not promise his voters he would do? If not, then you're saying that the majority of the people that chose Trump don't deserve to be heard and that only your views matter.

And don't even get me started on that business of, 'we didn't vote for him...he didn't get the popular vote'.

Why is it okay for previous presidents who won in the electoral college to be legitimized but not Trump? This is absolutely UNFAIR and selfish of anti- Trumpians. Remember, you take away California and Trump actually wins the popular vote anyway. To me, this is a clear indication that one state wants to bully the rest of the country into doing things their way and their way only. So UNFAIR.

Without getting into my country of origin, I will tell you this; we too are building a wall to stop illegal aliens from a neighboring Muslim country from getting in. These fundamentalists are really terrible human beings. We have lost so many lives to their suicide attacks. Friends and families losing their loved ones to these actions. I remember a time we were so scared of the attacks that we had to close offices in the daytime when working and verify you knew who was knocking on the door before letting them in. It was a terrible time and with a recent attack, last week to more precise, the fear is coming back. I just wish we had finished putting up our wall by now and that it was as strong as the proposed American one.

People have to be responsible for their own country. They have to build their own countries and stop the fundamentalism.

<comment><USER68> In what way does the U.S. have "unchecked immigration"?

Edit: also, you have a bizarrely pessimistic view of immigrants' and refugees' potential to contribute to their host country. My parents were part of the flood of refugees that came after the fall of Saigon. Like the incoming Syrians today, they were taken in by American families and lived off of welfare for years. Now they, and their children, contribute to the nation's bottom-line, never mind the goodwill that America incurs by taking in people of need.

<comment><USER67> I am against indiscriminate immigration policies.

There are always trade-offs. For every good immigrants such as your folks, there are those who are utterly destructive. This is just a fact. Therefore, you cannot be careless about who comes into your country. Some people just don't want the same things that you do. They prefer chaos because after death, they will meet their maker and get rewarded for their fundamentalism.

It then becomes a question of, do you accept the downside if the upside is as mundane as perceived goodwill. I think not.

I repeat, not all can be saved and for that matter, not all want to be saved. Some of them actually hate America and as soon as they are in, they will hurt Americans on purpose.

</comment></comment></comment><comment><USER69> Can US survive without "importing" OPEC Oil? bloom.bg/1O04ymn

<comment><USER13> Note that he didn't ban Saudis who have a fairly well known record for state sponsored terrorism.

They also have lots of oil.

</comment></comment><comment><USER70> If anyone thinks that this ruling is a surprise to the Trump administration, think again. I have no doubt that he conferred with his AG about his executive order and discuss possible outcomes such as a judge blocking his order. Maybe he expected this outcome?

Regardless, we'll see what his next move is.

<comment><USER71> > Maybe he expected this outcome?

If you subscribe to the "provoke outrage to cover something else" theory, this might be it: [https://www.washingtonpost.com/amphtml/politics/trump- holds-...](https://www.washingtonpost.com/amphtml/politics/trump-holds-calls- with-putin-leaders-from-europe-and- asia/2017/01/28/42728948-e574-11e6-a547-5fb9411d332c_story.html)

Trump added Breitbart's Bannon to the National Security Council, and demoted the Director of National Intelligence and the Chairman of the Joint Chiefs of Staff from it to make room.

<comment><USER72> > Trump added Breitbart's Bannon to the National Security Council

That's pure madness. That guy shouldn't even be close to a baseball bat, let alone sitting in on the NSC.

<comment><USER73> Out of curiosity, why? What things has he done? I'm quite ignorant on the man.</comment></comment></comment></comment>


The dangers of working for a startup vs a corporation - <AUTHOR> http://tikitakatechy.wordpress.com/2012/03/09/where-should-a-technologist-work-part-1/

<comment><AUTHOR> This is my first ever real blog post, id love any feedback especially from HN, as i spend quite a bit of time reading on here.

Thanks a million.</comment>


PHP based CMS that allows you to build websites for any purpose - <AUTHOR> https://warpknot.com <comment><AUTHOR> WarpKnot is a PHP/MySQL based CMS & framework that allows you to build websites for any purpose.

You could either build a small blog, or a corporate portal.

</comment><comment><USER2> You're charging money for something Wordpress will do for free.

<comment><AUTHOR> Yes and no. Actually, I'm charging money for a custom CMS with an admin panel that comes out of the box with 34 unique widgets which can be dropped in any page or blog post.

<comment><USER2> >Actually, I'm charging money for a custom CMS with an admin panel that comes out of the box with 34 unique widgets which can be dropped in any page or blog post.

Wordpress is also a CMS with an admin panel and _tens of thousands_ of plugins, many of which provide widgets that can also be dropped in any page or blog post. And I can get it for free and see the source code myself and judge its quality. Where can I do the same for WarpKnot?

I'm not saying this is a bad product, just that the market has already decided that PHP based CMS's aren't worth spending money on in most cases.</comment></comment></comment>


India's '$10 laptop' to cost US$100 after all - <AUTHOR> http://www.itworld.com/government/53931/indias-10-laptop-cost-us100-after-all <comment><USER2> Is that how much the US dollar is worth these days? It's worse than I thought...</comment>


Ask HN: Has the recent rulings/news affected your hiring efforts? - <AUTHOR> I am wondering about all these recent changes to immigration and how it is affecting small to large companies and their experience these first few weeks and their outlook on the future.<p>I've read some medium posts... but that's just a few cases. <comment><USER2> I am on the other side of the equation. Graduating this summer with Masters in Artificial Intelligence, I always wanted to immigrate to USA and work on solving interesting problems. But NO WAY I am doing this now. With all the recent things going, you never know when your life will be flipped upside down. And I can't risk investing so much efforts/time into such process (especially that I am muslim). I think there's a lot of other people like me. Even with the companies problem, I think, more people than ever now don't want to go to the US. Germany seems like a way much better choice now.

<comment><USER3> You can come to Canada, especially in Montreal, which is a good place for AI research.</comment></comment>


UK shifts NHS Covid-19 app to Google-Apple system - <AUTHOR> https://www.pocket-lint.com/phones/news/152606-uk-shifts-nhs-covid-19-app-to-google-apple-system <comment><USER2> Discussed here: [https://news.ycombinator.com/item?id=23562434](https://news.ycombinator.com/item?id=23562434) .</comment>


The Problem with Sencha Touch and PhoneGap - <AUTHOR> http://www.moneytoolkit.com/2011/05/the-problem-with-sencha-touch-and-phonegap/

<comment><USER2> What makes it really bad is that there is also this bug in mobile WebKit from four years ago that nobody has ever gotten around to fixing:

[http://blog.johnmckerrell.com/2007/03/07/problems-with- safar...](http://blog.johnmckerrell.com/2007/03/07/problems-with-safari-and- innerhtml)

Basically if you are at or near 100% CPU, Safari's HTML parser silently fails to parse your HTML.

Additionally, we have found this is not limited to the innerHTML property; we have observed the problem to happen with the W3C recommended method Range.createContextualFragment.

EDIT: formatting and cleanup

<comment><USER3> I had a big problem with HTML not parsing in phonegap. It was intermittent but far more often than I would expect for near 100% CPU. This fix on stackoverflow solved the problem entirely for me: [http://stackoverflow.com/questions/3644474/calls-to- update-d...](http://stackoverflow.com/questions/3644474/calls-to-update-dom- are-ignored-in-phonegap-app-with-iphone-3g-running-ios-3-0/5273001#5273001)

</comment></comment><comment><USER4> My own PhoneGap-based iPad app is going really well so far, practically indistinguishable from native, but for one thing: WebKit refuses to let you have manual control over hiding and showing keyboards. (I tried filing a bug, and it was closed as "works as intended".)

This makes me feel like I have one hand tied behind by back when creating UI flow, and it's maddening.

<comment><USER5> Do you have a link to your app? I'm really interested in seeing web apps that work similarly to native apps, I've yet to see a great example yet.

<comment><USER3> I'm working on a phonegap app at the moment. I definitely wouldn't say it looks native - I haven't really tried for that - but it is fast. You do have to be very careful about performance issues, but phonegap does make it exceedingly easy to incorporate native code if that is required. I would say, purely as a limited anecdote, that jquery mobile and other frameworks just weren't really fast enough for the performance I wanted to see.

<comment><USER4> Are you using any Javascript plugins at all? Regular jQuery, Zepto, Backbone, etc?

<comment><USER3> Regular jquery, jqote2, Kelvin Luck's jquery date picker, jquery autoresize plugin (though its not really working out so far) and all the phonegap javascript functionality.

</comment></comment></comment></comment></comment><comment><USER6> It sounds like most of these complaints are about mobile Safari and not specific to Sencha's libraries or PhoneGap.

<comment><USER7> True, to an greater extent, Ive rolled things together but I do try and not apportion the blame fully, by saying...

"The title may present a slightly unfair impression. Not all of these issues have anything to do directly with the PhoneGap or Sencha Touch codebase, but are simply limitations of browsers, web-views and performance of mobile devices, though Sencha Touch / Phonegap framework does inherit those problems (and go to some lengths to work round the issues)"

But there are defects and issues in both PhoneGap and Sencha Touch that I mention. But I also recognise that they are both doing a good job on balance to further the cause.

</comment></comment><comment><USER7> Updated with a video of the scroll lag problem <http://youtu.be/EEMCqqyeEDY>

</comment><comment><USER8> The irony is... running back to native platforms because the web sucks is _exactly_ why the web still sucks.

<comment><USER9> On the contrary, there is plenty of desire build cross platform applications on the web as evidenced by this article. How would this developer sticking to Sencha/Phonegap against contrary evidence improve the web for others?

<comment><USER7> Well, I am still plugging on with HTML5! for now, even if I am now wiring in iScroll4 to compensate for the poor scrolling of long lists!</comment></comment></comment>


Lack of ethics education for computer programmers shocks expert - happy-go-lucky https://www.stuff.co.nz/business/innovation/93629356/minimal-ethics-education-for-computer-programmers <comment><AUTHOR> I had an ethics course. It was complete rubbish. It was shared with physics, and mostly about how global warming was a bad thing. There was a little bit about the philosophy of ethics, but there was nothing about general morality. I don't think the manhattan project even came up.

Worse, the course is so universally dismissed by students, they had to make attendance mandatory to get people to show up. Hence, no-one shows up with anything resembling good-will.

In the end, it is the most universally despised course in physics and maths that I know of. Heck, it made me care _less_ about global warming that's how unsuccessful it was.

<comment><USER2> That's too bad. I enjoyed my college ethics course. The professor had been in international business and worked with all kinds of countries whose people expected bribes to do everyday business. The case studies were therefore super interesting and thought provoking. It was taught pretty open ended and there was never really a right or wrong answer. Your success depended on the strength of your argument.

<comment><AUTHOR> The quality of such a course depends very much on the attitude of the professor. In my case, it felt like the professor was glad to have another audience to preach to. I imagine he is the only professor enthusiastic about teaching this course.

<comment><USER2> Lol. Mine was enthusiastic too, due to his experience, and it was great. _shrug_

</comment></comment></comment></comment><comment><USER3> Stuff is like the Daily Mail of New Zealand, as a general rule you should assume everything at that site is complete garbage. That being said, this topic is definitely worth discussing.

I received my degree from a technical institute in NZ rather then one of the major universities. For each level we were required to take a semester (6 months) long paper in Legal and Ethics.

I enjoyed them at the time and have also found the knowledge gained to be extremely relevant in both my personal life and career.

The papers were quite broad and covered a range of topics including the traditional idea of "ethics", copyright law/infringement, the NZ Privacy Act, The Treaty of Waitangi [1]. We had an enthusiastic primary tutor and multiple guest tutors from the industry (privacy officer, lawyer etc). Thinking back, they were probably the best papers I took.

My day job now involves writing software that deals with the vast majority of New Zealanders medical data. The ethical "grounding" and the knowledge gained about the NZ Privacy Act in particular is quite literally at the front of my mind with every commit. It makes me extremely nervous that our educational institutes are shitting out software developers without any of this knowledge.

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

<comment><USER4> That's a bit of a harsh comparison. Stuff is the online format of all of Fairfax New Zealand's newspapers, some of which occasionally produce decent stories. Stuff is mostly just shitty poorly researched journalism rather than the Daily Mail's sensationalised tabloid bullshit.

</comment></comment><comment><USER5> I took a computer ethics philosophy course in college because I am into computers/programming as a hobby and I am also very much into philosophy.

I was the only English major/Philosophy minor in the class. Every other student was a computer science or IT systems major.

I was pretty shocked how lenient of an innate moral compass most possessed, I don't expect folks to be Kantian justicars by default, but C'mon. The vast majority seemed to align with the sort of base, selfish utilitarianism pervasive in America that eventually leads to "if it isn't breaking some law or as long as there's a loophole its good if it makes me money/benefits me or if it benefits a sheer greater quantity of people regardless of how horrendous the consequences are for those it doesn't benefit"

Nonetheless it was a fun class as we primarily looked at real life cases. As with other industries, some of the shit people pull is baffling--guess that's the result of years of delegating any ethics education whatsoever to the home/parental responsibility or to religion. Another reason I think a foundational education in philosophy should be mandatory in high schools across the US, if not junior high, just as some foundational education in computer science should also be mandatory these days.

<comment><USER6> I agree somewhat but I think it's a wider social problem - the society in general not really looking down on this kind of behavior. Especially from Americans, you often hear stuff like:

\- the company has a duty to make the most money possible legally for its shareholders, so we shouldn't criticize them for doing something shitty as long as it doesn't break the law

\- the employee can't be expected to lose their job over ethics, so no matter how shitty what they did was, they get a pass

So when a company does something shitty, nobody did anything wrong, as long as it was legal! The employees have to feed their children, the higher-ups have to do what's best for shareholders, and the shareholders are too detached from the company to blame.

Consider how sad it is that a massive amount of people literally holds the view that a financial incentive makes otherwise unethical behavior OK. Nobody will say that the fact that cheating on your wife is legal means it's ethical. But as long as you are getting paid for doing something shitty, it's not seen as unethical as long as it's perfectly legal by a lot of people.

When people _who are not even benefiting from them_ are defending shitty actions, you can't expect better from the people who _are_ benefiting, as they have an additional incentive to be unethical.

The idea that an economic incentive is an excuse to do something shitty needs to go away.

<comment><USER5> Good point. I find this sort of attitude is really hard to root out too once it's ingrained. I have one friend who I argue with all the time because, coming from a family of small business owners himself, he is always rushing to the defense of businesses and their less than venerable actions even when, as you said, he himself doesn't directly benefit from said seediness. No matter how many times I've tried to get him to see things from a more humanistic/humanitarian side, that "best for business" bug in him seems impossible to eradicate. It's like he's been indoctrinated to the point where it's become as fundamental and ineradicable as a biological survival instinct.

People come to take certain values as constitutive of living a 'meaningful' life and sleep on ever questioning them until it's far too late to really challenge them any more, then pass them off, unquestioned and unanalyzed, to their kids, and the rat race continues...

</comment></comment></comment><comment><USER7> One of the most valuable CS courses I took in college was my ethics course. Our honors college was pretty wide-ranging and rigorous, but CS students who weren't in it (I think I was the only one at the time?) were mostly B.Sc. students whose schedules were crammed with (largely superfluous) CS and math courses that left very little time for stuff that's actually useful, like the humanities. And because it was being taught by a CS prof, I went into it expecting it to be awful and boring and trite. Instead it was taught by our department head (who used to be at Watson) and Tom DeMarco (the author of _Peopleware_ ) and it dug into not just ethics as considered by philosophers (it was my first introduction to Alasdair MacIntyre, one that I've since expanded on pretty extensively on my own) but the characteristics of human, and not just computer, systems that lead people to do the wrong thing. It also introduced me to the book _Customers who viewed Normal Accidents: Living with High-Risk Technologies_ by Charles Perrow, which is so critical that I think it's the closest thing to necessary reading that anyone working in any technical field should be required to read.

I've heard a lot of people pooh-poohing the notion of ethics courses, but, frankly, most of the people I've worked with would've benefited from the exposure to thinking about their and others' actions outside of the most immediately utilitarian, mine-mine-mine setting. The framework of analysis and the vocabulary of ethics create a way to ask direct questions (and effectively demand answers) from people who choose to act in one way or another. It's valuable stuff.

<comment><USER8> >schedules were crammed with (largely superfluous) CS and math courses that left very little time for stuff that's actually useful, like the humanities.

That's funny, because so far in my college education I would say precisely the same thing except it'd be listing various superfluous humanities courses that I could have lived without taking time away from the STEM I'm actually there to study.

While I'm glad you got to experience the good stuff, I expect at most institutions this would be just one more torturous thing to get marked off the checklist.

<comment><USER7> So I just passed ten years since my freshman year of college, and I probably would have said the same thing you're saying now, then, and been as misguided about it as you are now. I went with a big puffed-up chest, sure that all I needed was the piece of paper that said I already knew how to code, and I was full of shit. Not because I didn't know how to code--I did, and at a fairly high level--but because it's everything else that actually matters once you graduate.

Unless you are a for-reals engineer--and that excludes somewhere north of 95% of software folks, maybe north of 99%--very little of the "STEM [you're] actually there to study" will apply when you leave college. If you're a CS grad, you'll use a little of it (a little more in some, generally niche fields), and it'll be useful, but by credit-hour it'll be the least applicable, least useful part of your curriculum. On the other hand, you know what is actually really useful for dealing with other people--the actual _important things in your life_ \--on a everyday basis? Political science. Microeconomics and the framework for understanding economic decisions. An understanding of history through both history classes and through the lens of literature so that you don't help repeat it. No bullshit--this is what makes you, the generic you, capable and functional and useful to other people way more than anything else. (It's usually the self-anointed "auto-didact" types who leap all over the equally-self-anointed "hacker" label that are the most tragically misled when they avoid this stuff in school. Getting rabbit-holed or led to crankdom is no bueno.)

Universities are finishing schools for educated humans, not for tradeworkers. If you're there to "learn STEM", you're there for the wrong purpose, and the willingness of educational institutions to indulge in STEM hyperspecialization is a tragedy in progress.

<comment><USER9> Plus "STEM" as a category is inherently bullshit anyway. Not the individual subjects in it, but the term as used to describe how you'll automatically have better career success if you pick from that category, because of post- secondary education magic.

</comment></comment></comment></comment><comment><USER10> At my university they touched upon ethics (30 min. lecture). I also received an ethics course at a business school. It helped me to form a vocabulary which I appreciate, but unfortunately nothing else. My best ethics education is having discussions with liberal arts students who care about societal minorities and societal challenges.

I'd argue that subjects like: racism, feminism, discrimination, poverty and similar topics confront a person to form an opinion and to empathise. I miss that in the traditional ethics education that I have received.

Still, the traditional ethics education was much better than receiving nothing. Especially people who go into fields like security should receive it.

<comment><USER11> This!

Dealing with the public, along with the occasional lefty PBS documentary, really opened my eyes. If it weren't for those experiences, I'd probably have ended up just as much of a whitebread, Breitbart, alt-right suburbanite as my coworkers.

</comment></comment><comment><USER12> Wow! One of the professors whom they interviewed and are quoting throughout the article is Richard O'Keefe: The author of "The Craft of Prolog" and very famous Prolog, Erlang and Smalltalk programmer in the respective communities who even has his own Wikipedia page:

[https://en.wikipedia.org/wiki/Richard_O%27Keefe](https://en.wikipedia.org/wiki/Richard_O%27Keefe)

His personal web page is also full of interesting texts about very diverse topics, and well worth a look:

[http://www.cs.otago.ac.nz/staffpriv/ok/](http://www.cs.otago.ac.nz/staffpriv/ok/)

<comment><USER13> So I went and read the piece on whether mathematics is invented or discovered, and found it to be surprisingly shallow. Hope this isn't an indication of his other work (which I'm much less qualified to evaluate).

<comment><USER12> Interesting. Personally, I found the observation about the pulsations of the jellyfish quite insightful and a good and very short counterargument against the quoted opinion.

There are other texts too on the page, which you may find better. I can only say that in all the language communities Richard used to post and still posts (notably Prolog and Erlang) he enjoys tremendous respect and is known for his technical expertise on very diverse topics. He is definitely a top-notch computer scientist and instructor who enjoys worldwide recognition in the relevant circles.

</comment></comment></comment><comment><USER14> One of my favorite computer security talks is this one, given by Alex Stamos in 2013: [https://www.youtube.com/watch?v=eEeHTQHTSgE](https://www.youtube.com/watch?v=eEeHTQHTSgE)

The whole talk is very worthwhile, and I recommend watching it.

Near the end of the talk, he essentially teaches a quick ethics class, describing a few hypothetical situations and discussing what the right option would be. At the end, he expresses how important it is to think about these things in advance, because it's a lot easier to make the morally right decision if you've taken the time beforehand to consider what is morally right.

Sometime after giving the talk, he joined Yahoo as CISO. There, he encountered one of the exact scenarios he described at 45:00 in his talk. (You may remember it, the Yahoo government spying story that came out last year: [http://www.businessinsider.com/marissa-mayer-secret-yahoo- se...](http://www.businessinsider.com/marissa-mayer-secret-yahoo- security-2016-10)) For what it's worth, he resigned quietly, exactly what he said in the talk that he would do in that situation.

I guess that demonstrates that he had the right idea to consider ethical dilemmas in advance. It certainly led me to think about issues I might encounter in my work.

</comment><comment><USER15> My CS degree program required an ethics course. It was an immense waste of time.

</comment><comment><USER16> This article is about New Zealand's schools but This is absolutely correct in the US too. We are seeing the results of programmers not understanding or caring about what their code skills can do. Viruses, black hat hacking and privacy invasion are partly due to people in the computer industry not understanding or caring about ethics. None of my computer courses included ethics as part of the lectures or reading. But I've taken business courses that at least touch on ethics. And if you are planning to get a degree in Law,Medicine,Genetics and business you will be taking courses that teach ethics. You can even take complete courses on the subject to meet requirements but in the computer sciences field it's not standard or required.

With the impact computer technology has on our society we definitely need to start teaching it in schools.

<comment><USER17> Is there any evidence that "teaching ethics" works? I wouldn't expect it to, but I'd be happy to be wrong.

> Viruses, black hat hacking and privacy invasion are partly due to people in > the computer industry not understanding or caring about ethics.

Yes, but the breakdown is .1% not understanding and 99.9% not caring (which typically takes the form of rationalization).

<comment><USER18> You can have effective or ineffective teaching of ethics, but you can teach it. We aren't born ethical creatures, it is a learned behavior.

<comment><USER17> Kids learn at a very early age to pay attention to what people do over what people say. "Do as I say, not as I do" is always going to be ineffective.

</comment></comment></comment></comment><comment><USER19> Told my alma mater the same thing for a 5 years post graduation survey.

Mind you, I was on the free software club, for example, and ethic was always there for some of us.

But I encourage everyone to write to the director of their Comp. sci. / Eng. departement to ask them why is this field not deserving of ethical questioning and/or what do they plan on doing to fix this.

I know lots of 20 yo might consider this a boring waste of time or not understand the importance of this kind of education, but sadly that reaction makes this an even more pressing issue to think about and would alone justify the teaching of ethics in the context of this field's short history...

We're on the verge of big fights to preserve and improve the Internet's openness & neutrality along accessible general purpose computing for all and other basic foundations some are taking for granted while lobbies are fighting against them.

But the future of free speech depends on this education and foreshadowing by an educated population...

Not enough people are fighting back and older politicians need to be shown a few things we might see coming before the rest of the population is able to catch up.

(N.B. Same goes for many fields, but computing is now such an important and direct part of the social tissue, got there so fast, that it's getting even more important everyday.)

<comment><USER2> Thanks for your comment, it's good.

</comment></comment><comment><USER20> I'm a student currently majoring in business and in computer science and the difference between classes at the two schools is stark. To maintain one of its' business accreditations the school has to teach ethics in every single business class. By comparison not once have I ever heard a thing about ethics from any of my CS classes.

While I suppose you could argue that business students will be in positions of power, it feels out of place when every other student is.

</comment><comment><USER21> Since we're sharing experiences, I had a pretty interesting ethics course in college. We were taught consequences, not morals, since trying to teach a bunch of twenty-somethings morals that they may or may not need to exercise in their careers was deemed impractical. The class mostly revolved around what might happen in situations like using substandard materials, whistleblowing, etc.

</comment><comment><USER22> Everybody who is in the periphery of hacker (in the traditional meaning as in "Hacker News" and "hacker space", not in the meaning used in media) probably knows the hacker ethic that was originally formulated by Steven Levy:

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

</comment><comment><USER23> I had to take a few of those courses but I doubt they make much sense. I felt that you are mostly discussing "don't so bad things" all the time, captain obvious stuff... There's the one type of people who care about things anyway and the other type who don't. Can't imagine that the second type can be convinced by course blabla.

</comment><comment><USER24> There is a code of ethics by NSPE (National Society of Professional Engineers): [https://www.nspe.org/resources/ethics/code- ethics](https://www.nspe.org/resources/ethics/code-ethics)

And as programmers are calling themselves engineers, they should adhere to that code.

</comment><comment><USER11> With "ethics" being just another word for the codified value-system of "experts", in what bizzaro world would an "expert" not be "shocked"?

</comment><comment><USER25> My college required a CS specific ethics course. Everything the teacher said had an obvious rebuttal and when I brought them up he would agree with me and move on. It was at that time I picked up TIS-100 and played that in class rather then sit there and be spoon fed the dribble.

Finished the first set of puzzles and the hidden one all in the first half of the semester!

</comment><comment><USER9> Haven't read the article yet, but this headline is dumb.

If the subject of the headline is an expert, how could they be shocked? That would imply they've hit a limit to the relevance of whatever their expertise is.

<comment><USER9> Now I've read the article. A better headline would be "One old man is surprised that the world doesn't work the way he thinks it should."

</comment></comment><comment><USER26> We can't have experts being shocked now, can we?

</comment><comment><USER27> Lack of ethics education for journalists (and politicians) shocks me...

Seriously: Put it in school, seems to be helpful (not only) for most other professions.

<comment><USER9> I don't know if it would help for those two. The problems are less about knowing what's ethical behavior and more about disagreements regarding how the world ought to be.

</comment></comment><comment><USER28> > Auckland University computer science associate professor Ian Watson, said > this was a problem because the mostly 20-something-year-old, caucasian males > creating apps were making race and gender divides worse.

Oh, fuck you and the horse you rode in on. The tech industry has given everyone in the world access to nearly all of humanity's knowledge. It has enormously extended everyone's ability to communicate. It has made it easier to learn, to solve problems, to find a job, to start a business, to talk and trade and work with people all over the world.

For less than $150 [0], you can buy a computer that is infinitely more powerful than the one I used to teach myself programming as a child, and gain access to all of the above.

And we have to get dressed down by clowns who charge teenagers thousands of dollars to fill their heads with garbage, leaving them saddled with debt and with no usable skills? You have to be kidding me.

Make no mistake, these maneuvers are not at all about "ethics". They are about a certain breed of parasites looking for new ways to latch onto a productive industry.

That said, a basic liberal arts education (not taught by those clowns) would certainly be useful to engineers. Or to anyone, really (I studied the history of philosophy in high school, didn't you?). If nothing else, it would give them the confidence to rebuff this kind of nonsense.

[0]: [https://www.google.com/search?q=chromebook&oq=chromebook&aqs...](https://www.google.com/search?q=chromebook&oq=chromebook&aqs=chrome..69i57j0l5.1367j0j7&sourceid=chrome&ie=UTF-8#tbs=vw:l,mr:1,cat:328,pdtr0:966482|966483,price:1,ppr_max:150,init_ar:SgVKAwjIAkoKUggI0v46INP- Og%3D%3D&tbm=shop&q=chromebook)

<comment><USER29> Would you please not rant like this on Hacker News?—regardless of how wrong someone else is or how bad an article. You've done this before, and it lowers the quality of discussion.

<comment><USER28> Sorry about that. Please go ahead and remove the comment, I can't.

</comment></comment></comment><comment><USER30> Where would one even begin to design an ethics course for programmers, though?

Our reach is pretty wide and on graduation, one person might go to work for an open source company, requiring one set of ethics, and another might go to work for a government agency, requiring a completely different set.

How do you design a curriculum that satisfies both sets of needs, unless you just want to get totally political?

<comment><USER31> You need to pair it with with specific topics on safety (preserving human life, body, and property), privacy (a grayer area), and professional ethics (responsibility to clients, self, society).

Practical discussions on why specific systems have failed and in what ways, particularly where ethics and professional violations can be observed.

Classically, the Therac 25 as an example of failure at many levels. See Tragic Design (a recently published O'Reilly book) for cases of bad design leading to tragic or potentially tragic results. A number of them could be turned into case studies in ethics. Examine why security breaches and privacy breaches happen. What obligation do we as engineers have to the public, the customers, and the clients acquiring the systems we make?</comment></comment>


Kleroterion - <AUTHOR> https://en.wikipedia.org/wiki/Kleroterion <comment><USER2> While Athens was not selecting ballots, but representatives directly, random ballot voting[1] is related and is one of a very few voting systems in which strategic voting (voting for other than your preferences in order to get the desired outcome) is never correct.

There are systems that make strategic voting not correct in most (if not all) real-world settings, but those are so complicated that IMO strategic voting would still happen just because people don't understand the system.

I would love to see random ballot voting for electing any sufficeintly large set of representatives, it's simple and provides proportional representation.

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

<comment><USER3> Non-determinism isn't great though.

It could be useful to allocate a number of seats, but then deciding who filled those seats would be a matter of headache (or "trust the party!" goes into effect and removes direct voting)

<comment><USER4> Determinism can be readily added by means of a simple procedure (the name of which I have forgotten—hopefully a fellow commenter can chime in here): Along with their vote, each voter submits a random number between 1 and _N_ , where _N_ is the number of voters. To select which ballot should decide the vote, all numbers are publicly revealed and added together, modulo _N_ : the resulting number selects which ballot should be used. It is not possible for any individual or group to fix the final number in advance, since even a single non-cooperating individual can alter the final number in an arbitrary way.

Obviously this simple form can only be used if _N_ is known in advance, but I _think_ that if you instead select a sufficiently large maximum (several times larger than the probable _N_ ) the randomness property should remain.

</comment></comment></comment><comment><USER5> I named a project after these! [https://www.kleroteria.org](https://www.kleroteria.org)

<comment><USER6> Interesting idea/project, never heard of the listserve or anything similar. Site is clean and fast, nice work ;-) A few questions if I may. How many people are registered? If someone is selected (randomly), can he/she be selected again next week? Do you plan to release/make public available all previous emails?

<comment><USER5> Thanks!

There's around 1k members right now. I stole the 10k catchphrase from The Listserve. Consider it aspirational!

Yes, people can be selected multiple times, but they must submit a post before they can be selected again.

No, I don't currently plan to release the posts. I might change that at some point but I'd want authors to opt in -- even though the license allows it without their consent I doubt everyone understands that.

</comment></comment></comment><comment><USER7> Look at that! And then look at contemporary hiring. A phone screen, a video interview, an on-site, another on-site, a take-home exam, psychometric testing, dowsing, crystal pendulum, and it still doesn't work better than casting lots.

<comment><USER8> >it still doesn't work better than casting lots.

i don't know about that. Using all these tools you listed the companies have been able to "hire the best, the top 1% (or 2%)" while casting the lots they would definitely not be able to do that.

<comment><USER9> > the companies have been able to "hire the best, the top 1% (or 2%)"

Citation strongly needed. Having worked with a lot of big companies, I'd say Top 20% is still generous.

<comment><USER8> 1 or 20 doesnt matter - for any N>0 only one company can do "top N", not all of them who pretend to achieve that, and they wouldn't be able to pretend it if they used the random approach like the GGP suggested.

</comment></comment></comment></comment><comment><USER10> It's interesting that the people being chosen with a kleroterion and black and white dice were called 'dikastes', since the mechanic was literally 'die casting' (as in die rolling, not the manufacturing process).

</comment><comment><USER11> This is cool, but why didn't they use 5 chests with tickets on them, drawing names round-robin from the chests?

<comment><USER12> Probably for technological reasons: they didn't use paper so the tokens had two problems: 1 - they were non-uniform so could in theory be biased and 2 - typically the tokens were made of dried clay, so could easily fracture.

For casting votes potshards were typically marked by the voter to indicate preference, then discarded.</comment></comment>


COMMANDO: Manage servers easily online. - <AUTHOR> https://commando.io/

<comment><USER2> This is really well done for a beta. I'm pleasantly surprised at how well it is working and how well laid out it is. I wish this would get some more upvotes, I'd love to see some additional discussion on this.</comment>


C Internals - <AUTHOR> http://www.avabodh.com/cin/cin.html <comment><USER2> For those who are interested to hone their skills in translating C to assembly language just for the sake of grokking a C compiler, you might want to read this book:

Assembly language and computer architecture using C++ and Java Book by Anthony J. Dos Reis

From book's description:

Students learn best by doing, and this book supplies much to do with various examples and projects to facilitate learning. For example, students not only use assemblers and linkers, they also write their own. Students study and use instruction sets to implement their own. The result is a book that is easy to read, engaging, and substantial.

I'm not affiliated with the author though. This book helped a lot in my career as a hardware and firmware engineer.

It talks about not only C language but C++. You'll be able to translate a C++ class into assembly language by hand. The drawback is that you'll learn a hypothetical CPU but the concepts are still the same with the real world CPU. C internals could supplement it as well.

<comment><USER3> I can't improve upon your recommendation, but I'll second it, from the point of a firmware / security / reverse engineer-er.

<comment><USER4> [https://gist.github.com/jart/fe8d104ef93149b5ba9b72912820282...](https://gist.github.com/jart/fe8d104ef93149b5ba9b72912820282c)

</comment></comment></comment><comment><USER5> [http://www.avabodh.com/cin/programstructure.html](http://www.avabodh.com/cin/programstructure.html)

        ...
        void main()
        ...

That's where I stopped reading.

Since this comment is getting downvotes, I'll explain. The "void" keyword was introduced in the 1989 ANSI C standard. That same standard specified that the valid definitions for the main functions are:

        int main(void) { /* ... */ }

and

        int main(int argc, char *argv[]) { /* ... */ }

or equivalent (or implementations can support other forms). There has never been a version of C in which "void main()" is a valid way to define the main function.

It's a small detail, and yes, many compilers will let you get away with it (the language doesn't require a diagnostic), but anyone writing about C should be aware of this, and should set a good example by writing correct code.

Maybe the site is OK other than that, but it doesn't inspire confidence.

<comment><USER6> Just for some context, the standard specifies an int return type for the purpose of returning a meaningful value back to a hosting operating system.

However, in the specific context of stand-alone or freestanding programs, the "void main()" definition would be absolutely nonconsequential, since there is no host to return a value to.

<comment><USER7> > However, in the specific context of stand-alone or freestanding programs, > the "void main()" definition would be absolutely nonconsequential

One possible consequence I can think of: If your program is safety-critical (or even otherwise) you might be interested in running static analysis or verification tools on it. These tools implement the C standard, so they would emit a diagnostic on the use of void main.

Other than that, sure, the language police will not come and break down your door. If your compiler's docs say that it accepts this construct with the meaning you want, it is indeed an inconsequential, though also _completely unnecessary_ , deviation from the standard.

</comment></comment></comment><comment><USER8> while very educative, it just teaches one possible translation from C.

Lets pick the "Translation of Arithmetic Operations" example and convert it to float instead of int

        int a = 2;
        int b= 3;
        int c = 24;
        a = a + b;
        a = a + b * c;

[http://www.avabodh.com/cin/arithmeticop.html](http://www.avabodh.com/cin/arithmeticop.html)

And pack it into a function so that Golbolt can compile it.

        float hn_demo(void) {
          float a = 2;
          float b = 3;
          float c = 24;
          a = a + b;
          a = a + b * c;
          return a;
        }

And now pick a CPU that isn't that good with floating point, like AVR, using GCC 4.5.4, and we get:

            ldi r24,lo8(0x40000000)
            ldi r25,hi8(0x40000000)
            ldi r26,hlo8(0x40000000)
            ldi r27,hhi8(0x40000000)
            std Y+1,r24
            std Y+2,r25
            std Y+3,r26
            std Y+4,r27
            ldi r24,lo8(0x40400000)
            ldi r25,hi8(0x40400000)
            ldi r26,hlo8(0x40400000)
            ldi r27,hhi8(0x40400000)
            std Y+5,r24
            std Y+6,r25
            std Y+7,r26
            std Y+8,r27
            ldi r24,lo8(0x41c00000)
            ldi r25,hi8(0x41c00000)
            ldi r26,hlo8(0x41c00000)
            ldi r27,hhi8(0x41c00000)
            std Y+9,r24
            std Y+10,r25
            std Y+11,r26
            std Y+12,r27
            ldd r22,Y+1
            ldd r23,Y+2
            ldd r24,Y+3
            ldd r25,Y+4
            ldd r18,Y+5
            ldd r19,Y+6
            ldd r20,Y+7
            ldd r21,Y+8
            rcall __addsf3
            mov r27,r25
            mov r26,r24
            mov r25,r23
            mov r24,r22
            std Y+1,r24
            std Y+2,r25
            std Y+3,r26
            std Y+4,r27
            ldd r22,Y+5
            ldd r23,Y+6
            ldd r24,Y+7
            ldd r25,Y+8
            ldd r18,Y+9
            ldd r19,Y+10
            ldd r20,Y+11
            ldd r21,Y+12
            rcall __mulsf3
            mov r27,r25
            mov r26,r24
            mov r25,r23
            mov r24,r22
            mov r18,r24
            mov r19,r25
            mov r20,r26
            mov r21,r27
            ldd r22,Y+1
            ldd r23,Y+2
            ldd r24,Y+3
            ldd r25,Y+4
            rcall __addsf3
            mov r27,r25
            mov r26,r24
            mov r25,r23
            mov r24,r22
            std Y+1,r24
            std Y+2,r25
            std Y+3,r26
            std Y+4,r27

Which includes calls to a floating point emulation library and quite different from the x86 example, with numbers using multiple registers.

So more of an heads up, sometimes the C translation to Assembly isn't as direct as one might think.

<comment><USER9> Perhaps more telling/less nit-pickable is when you modify the function to be

        float hn_demo(float a, float b, float c) {
          a = a + b;
          a = a + b * c;
          return a;
        }

and let the compiler actually optimize with -02.

<comment><USER8> Sure, but it still boils down to the fact that it isn't as 1:1 as many think it is.

</comment></comment></comment><comment><USER10> Minor quibble:

The section on local variables assumes a downward-growing stack. This is completely fair, because the introduction specifies that the articles deal with an x86 world. What gets missed out is the fact that the direction of stack growth is determined by the processor :)

This is not really a complaint ... it just seemed to me like a missed opportunity to mention something interesting.

<comment><USER11> Try to name one processor with an upward-growing stack... I bet most people who are otherwise familiar with this material can't.

(I'm not saying you're wrong --- I personally know two ;-)

<comment><USER10> SPARC and ARM are the only ones I know, and the SPARC is the only one I've worked with in a past life. (Edit: SPARC allowed you to decide the direction of stack growth, it wasn't really fixed. I've heard that ARM does the same. So in some sense, I didn't really answer your question :) ).

<comment><USER12> Original Arm had an ISA which didn't mandate a stack direction -- the stack pointer register (r13) was not special and it was only the calling convention that decreed that it was the stack pointer. The instruction set's LDM/STM (load/store multiple) insns supported both decrementing and incrementing the base register either before or after the accesses, which meant you could use them to implement an ascending stack if you wanted. However in practice the usual calling convention was "r13 is the stack pointer, and the stack descends". When the Thumb instruction set was added, this convention was baked into some instructions because the 16-bit opcode size didn't allow spending bits on the fully flexible "any base register, any direction, any way" operations the 32-bit Arm encoding used. In the M-profile variant of the architecture, the calling convention is heavily baked into the exception handling model (taking an exception/interrupt pushes a stack frame onto the stack) so the stack must be r13 and grow downwards. In the 64-bit Arm architecture, SP is no longer a general purpose register; I think in theory you could implement an ascending stack, but since the [reg+offset] addressing mode that allows the largest offset value takes an unsigned offset, accessing stack slots via [sp+N] is more natural than the [sp-N] an ascending stack would prefer.

Summary: original Arm gave the software the flexibility to implement an ascending stack, but in practice the stack was always descending, and more recent architecture changes assume this to a greater or lesser extent.

<comment><USER10> Thank you, I learned something new today!

<comment><USER13> It's not just the direction of the stack: in theory, there are two possible kinds of downwards-growing stacks, a 'full' SP points to the last used entry, whereas an 'empty' SP points to the next free entry. It all depends upon how you 'push' something on to the stack: do you decrease the SP before or after writing the data?

ARM let you choose either approach (making four different stack configurations in total!) - this flexibility is because ARM didn't have any specialised 'push' or 'pop' operations, you read/write to the stack using the normal load/store ops, which have a variety of addressing modes.

</comment></comment></comment></comment></comment></comment><comment><USER14> The use of AT&T syntax here is unfortunate. When the processor documentation and every single other toolchain out there uses a different syntax, you should use that syntax too.

EDIT: Would any of the people downvoting this comment care to explain their affection for this historical mistake? I have never understood why anyone would choose it.

<comment><USER15> > When the processor documentation and every single other toolchain out there > uses a different syntax, you should use that syntax too.

All the GNU tools, and many of their clones, use AT&T syntax. I think I run into it more often than Intel, and I turn on the option for the latter where I can. It's really prevalent.

<comment><USER16> Same for me. Usually just because of the ubiquity of gcc and its ilk.

</comment></comment></comment><comment><USER17> Per Vognsens description of how a compiler can lower C statements might be of interest! He lowers the code to RISC-V but the techniques and explanations is platform-independent.

[https://raw.githubusercontent.com/pervognsen/bitwise/master/...](https://raw.githubusercontent.com/pervognsen/bitwise/master/notes/asm.txt)

</comment><comment><USER18> For someone who wants to know how a C compiler converts C to assembly there is no better example than:

[https://github.com/oriansj/mescc-tools- seed/blob/master/x86/...](https://github.com/oriansj/mescc-tools- seed/blob/master/x86/NASM/cc_x86.S)

</comment><comment><USER19> i learned those common patterns by using godbolt.org

</comment><comment><USER20> I think this is a smart way to introduce C.

</comment><comment><USER21> Thank you! This is very interesting.</comment>


Three Steps to Kickass Customer Service - the best investment a company can make - <AUTHOR> http://spreadsong.com/three_steps_to_kickass_customer_service_and_why_its_the_best_investment_your_company_can_make_ Another good tip is to actually respond to your customers, especially when they are trying to give you more money.<p>Currently waiting for Libyan Spider to respond to my third ticket trying to get access to my account so I can renew two domain names I have with them. Not pleased. <comment><AUTHOR> Another good tip is to actually respond to your customers, especially when they are trying to give you more money.

Currently waiting for Libyan Spider to respond to my third ticket trying to get access to my account so I can renew two domain names I have with them. Not pleased.

</comment><comment><USER2> The best thing I've found that works is to put yourself out there. Making it as easy as possible to contact your company and get in touch with an actual person keeps any small problems from exploding into a huge one.</comment>