209 points · by doppp · 11y ago · 150 comments
Previously on HN: https://news.ycombinator.com/item?id=9419035
Entry[Square] = BLANK; // Could be moved out of the loop
Maybe I'm reading too much into it, but this type of thinking makes me smile. The guilty perfectionism, "this can be improved."Were I from Singapore, I'd be happy to see it in the person in charge of my country.
Can we please just ignore this dictator and be amazed about code of other people instead?
It just feels wrong.... I think freedom of speech is a very very important part of the hacker community. I think no sane person would want this person in charge of his country. Coder or not.
"I tell you what freedom is.
Freedom is being able to walk on the streets unmolested in the wee hours in the morning, to be able to leave one's door open and not fear that one would be burgled. Freedom is the woman who can ride buses and trains alone; freedom is not having to avoid certain subway stations after night falls. Freedom is knowing our children can go to school without fear of drugs, or being mowed down by some insane person with a gun. Freedom is knowing that we are not bound by our class, our race, our religion, and we can excel for the individuals that we are - the freedom to accomplish. Freedom is living in one of the least corrupt societies in the world, knowing that our ability to get things done is not going to be limited by our ability to pay someone. Freedom is fresh air and clean streets, because nothing is more inimical to our liberty of movement than being trapped at home because of suffocating smog.
These are the freedoms that Singaporeans have, freedoms that were built on the vision and hard work of Mr Lee, our first Prime Minister. And we have all of these, these liberties, while also being one of the richest countries in the world."
The whole article is great http://www.straitstimes.com/news/singapore/more-singapore-st...
Singapore isn't a free country. It's very efficient, rich and safe, yes.
Just as long as you're of Chinese ancestry, of course.
I actually like that there's lots of little experiments going on, trying any number of positions on all the little dials of society. Time will tell which ones work.
Its also LEO abuse because their system allows unlimited detention without charge. Homosexual rights are non-existant: Prime Minster Lee Hsien Loong has spoken dismissively of the challenges to article 377A: “Why is that law on the books? Because it’s always been there and I just think we leave it. I think that’s the way Singapore will be for a long time.”
If that wasn't bad enough:
Singapore’s Media Development Authority issued a regulation effective on June 1 that banned major news websites available in Singapore from “advocating homosexuality or lesbianism.”
All Foreign domestic workers are excluded from the Employment Act, which provides employment protections.
Its easy to sit here on your expensive computer and fast internet connection in a Western country and pretend living under a regime like this is wonderful. You're not a gay man being jailed for loving your partner or a poor Philipino being beaten by his employer because he cant work 18 hour shifts everyday. Apparently, curtailing speech didn't fix these issues, so why are you advocating for it?
>I actually like that there's lots of little experiments going on,
We've gone down this path a million times. Its not surprising that it brings the same results as before.
It is easy to be an anarchist or communist when you dont have to live in such a place.
And "better society" isn't the only reason to believe in "free speech". Another reason is the moral principle that one should not be imprisoned for a political opinion.
I guess I finally understand the whole "I want a president I could play sports / grab a beer / whatever with" sentiment.
This always seemed like an excuse by a defeated people. They know their person in charge is a nightmare and limits their ability to be free actors, so they just rationalize it away in a Stockholm Syndrom-like way. "Hey he's a good guy, you'd like him if you met him."
I see this a lot with Russians who know full well Putin is dictator for life and they essentially have no rights or recourse against his administration, but play up a positive bullshit spin like "standing up to NATO/Nazi killers in Ukraine" or "bringing us back our Soviet glory." Its pathetic and on some level even the die-hards know it.
I think it would be nice if there were more countries that presented different types of trade-offs, and then some mechanism for people to decide what type of country they want to live in.
The problem is that the people have no way to overthrow or even audit their government. That's all nice and roses if the government is acting in good faith of its citizens (which people here claim is happening in singapore). But what if the next person is just totally insane? And abuses all his powers? You have no way to protect yourself from an abusive government. Which is very concerning.
Maybe I'm too extreme in this? I don't know. But at least I can decide right?
The question is, however, if this is a regime we'd like to live in. A regime where dissent is closely regulated and suppressed (including through canning). A friend's father, formerly an editor of the WSJ, is banned from Singapore for writing an article critical of the boss.
I don't think it's a coincidence that Silicon Valley is in CA and has attracted millions throughout the world, to program. People take risks and failure is a badge of honor - not a stain on your family's honor.
Meanwhile Singapore has someone who was, according to his ex-adviser, a great mathematician/programer. But then he joined the consultant/political class.
"Well, at least our country has freedom of speech, brah!"
Yeah, no. I'd rather live in a country that provides a good living for its citizens and doesn't squander its wealth war mongering around the world for the sake of protecting some vague notions of "freedoms".
My life now is the antithesis of my life in San Francisco (worst city I have ever lived in overall), and I couldn't be happier.
Or maybe there's no correlation at all? In the sense that NO, it's not better to have a presidnet with this characteristic thna without, it's equally likely that both the president with and without this can be a bad politician.
Would you be equally happy to see Herman Cain as President of the US? He also has Masters in CS and spent the early parts of his career as a programmer.
Great, he used to program and displayed a handful of positive character qualities in doing so. A lot more than that is required to be an effective leader of a country.
It demonstrates he can write a sudoku solver in C++, I don't see how this has anything to do with being in touch with reality.
He is a senior wrangler.
Programming might not be that hard to pick up if you had done it before, couldn't this code have been written on a 25 year old computer to compile with a Borland era compiler?
Because the wider population don't understand programming and see it as magic, I fully expect his popularity to do well, he is practically a hacker in their eyes, able to conjure up magic and demonstrate skill.
"Because the wider population don't understand programming and see it as magic, I fully expect his popularity to do well, he is practically a hacker in their eyes, able to conjure up magic and demonstrate skill."
The circle jerking in this thread rubs me the wrong way - "this guy must be awesome, he can pass a 1st year 'introduction to computer programming' class!". Must be the cognitive dissonance - there are people still saying Hans Reiser was surely framed, because how could a programmer be anything but God's gift to mankind?
The general public don't think of you as some sort of magic hacker because you code for a living, sorry.
So yeah, extra curricular skills and fancy degrees and academic credentials may not translate into a good leader of the country.
Speaking in public (especially to very large crowds) and not turning into a nervous wreck is not a useful skill?
3 law, doctor
2 law, master
2 law, candidate (~bachelor)
1 agriculture, doctor
1 social sciences, doctor
1 none, farmer + bank manager
1 military, field marshal
1 teacher (primary school)http://www.telegraph.co.uk/news/science/science-news/9359579...
It's been over a year since I've thought about solving sudoku, but here's how I solved it then:
Row[1] : 800000000
Row[2] : 003600000
Row[3] : 070090200
Row[4] : 050007000
Row[5] : 000045700
Row[6] : 000100030
Row[7] : 001000068
Row[8] : 008500010
Row[9] : 090000400
8-- --- ---
--3 6-- ---
-7- -9- 2--
-5- --7 ---
--- -45 7--
--- 1-- -3-
--1 --- -68
--8 5-- -1-
-9- --- 4--
812 753 649
943 682 175
675 491 283
154 237 896
369 845 721
287 169 534
521 974 368
438 526 917
796 318 452
Level Counts:
(8, 7): 1 (7, 7): 2 (7, 2): 3 (7, 5): 5 (2, 2): 7 (6, 2): 11
(1, 2): 20 (1, 7): 33 (6, 7): 51 (4, 7): 62 (2, 7): 86 (5, 2): 114
(8, 2): 160 (5, 3): 195 (5, 8): 217 (5, 9): 260 (5, 1): 317 (5, 4): 371
(4, 8): 398 (4, 9): 456 (6, 9): 473 (6, 1): 440 (6, 3): 429 (6, 5): 407
(6, 6): 392 (4, 3): 364 (4, 1): 360 (7, 6): 330 (7, 1): 302 (2, 1): 264
(7, 4): 229 (8, 5): 200 (4, 5): 164 (1, 5): 134 (2, 5): 115 (2, 6): 92
(1, 6): 71 (3, 6): 63 (4, 4): 47 (1, 3): 41 (8, 6): 37 (3, 4): 28
(3, 1): 20 (8, 9): 15 (2, 9): 12 (2, 8): 7 (1, 8): 4 (3, 9): 4
(3, 8): 1 (8, 1): 1 (1, 9): 1 (9, 1): 1 (1, 4): 1 (9, 3): 1
(9, 4): 1 (9, 5): 1 (9, 6): 1 (3, 3): 1 (9, 8): 1 (9, 9): 1
Count = 7826
Total Count = 13080
int Possibles = Block[BlockIndex] & Row[RowIndex] & Col[ColIndex];
while (Possibles) {
int valbit = Possibles & (-Possibles); // Lowest 1 bit in Possibles
Possibles &= ~valbit;
Entry[Square] = valbit;
Block[BlockIndex] &= ~valbit;
Row[RowIndex] &= ~valbit;
Col[ColIndex] &= ~valbit;
is more generally: set<int> possibles = block[block_index].intersect(row[row_index]).intersect(col[col_index]);
while (!possibles.is_empty())
{
int value = possibles.pop();
entry[square] = value;
block[block_index].remove(value);
row[row_index].remove(value);
col[col_index].remove(value);This also can be considered as a positive fact for me, once in my country, it's common to find politicians that even doesn't have any degree (including a very recent president).
Experience managing the resources of a population of 5.5 million, experience on the world stage, programming and problem solving ability, his alma mater include Cambridge and Harvard, and military service, able to maintain close relationships with important people (including the President of the United States.)
He would absolutely get a job in Silicon Valley.
Knowing a bit of C++ and understanding an algorithm to make it solve a puzzle is largely useless in this context. Understanding a bit about technology at (close to) the lowest level, doesn't signify an understanding of how the internet works, how encryption systems work, how network security or the communications infrastructure works. Without an understanding of these in today's world of the communications and the internet, you may as well not understand how to program at all. Where we see technology failing the people (certainly in North America) are because legislators are largely incompetent in this context and seek to protect corporate interests over the needs of the people. I would say, being a systems administrator or systems analyst would make you far more capable of understanding the implications of technical bills and regulations than understanding a bit of C++.
https://www.facebook.com/leehsienloong/photos/a.344710778924...
There are tens more languages that are more modern and "aspirational"
It was long time ago I read that Google was directly rejecting the CVs that have typos in them which I find it annoying and not nice. And today I see this title typo in their error page which is totally fine and a mistake that i also make sometimes (leaving shift button little early while pressing 1)
<title>Error 500 (Server Error)!!1</title>
"For Google — a company that sees 50,000 résumés a week — the typo is one of five résumé mistakes that will immediately land yours in the "no" pile." [0]
http://www.businessinsider.com/google-resume-mistake-2014-9?...
Human beings will make mistakes Google, there is no need to extremely force it to otherwise.