Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror

Comment Re:When Helping Hurts (Score 1) 268 268

What terrible advice. I found a summary of that book online (http://southwood.org/files/pdf/WhenHelpingHurtsSummary.pdf) and it looks like a bunch of christian crap. A quick sample:

"Bryant Myers, a leading Christian development thinker, argues that in order
to diagnose the disease of poverty correctly, we must consider the fundamental
nature of reality, starting with the Creator of that reality. Myers notes that the
Triune God is inherently a relational being, existing as three-in-one from
eternity. Being made in God’s image, human beings are inherently relational as
well. Note that human life is not all up for grabs! God designed humans to be a
certain thing and to operate in a certain way in all of these relationships."

Then it goes on to analyze poverty as the failure of relationships, starting with the relationship to god. I stopped reading after that.

Comment Positive or negative infinity? (Score 4, Informative) 157 157

For most complex numbers the sequence will most certainly not converge to positive or negative infinity, whatever those mean. When dealing with complex numbers it only makes sense to talk about a single infinity, which is the point at infinity of the projective complex line (a.k.a. "Riemann sphere").

Comment Re:It depends (Score 4, Informative) 486 486

[...] For instance, their paper says that concatenating a million one byte strings into a single million byte string takes 274 seconds. That should take much less than one second.

I didn't RTFA, but after reading this I am certainly not going to. This C++ piece of code takes around 0.01 seconds to run on my computer:

#include <iostream>
#include <string>

void build_string(std::string &s, std::string r) {
    for (int i = 0; i < 1000000; ++i)
        s += r;
}

int main() {
    std::string s;
    build_string(s, "a");
    std::cout s.length() '\n';
}

Submission + - Ask Slashdot: Should I let my kids become American citizens? 3 3

An anonymous reader writes: Dear fellow Slashdotters,

Can you help me decide whether to allow my small daughter and son to become American citizens?

I am American and my partner is Swedish. We have both lived in Belgium for many years and have no plans to leave. I became a Belgian citizen some years ago and kept my American citizenship. My partner has both her original Swedish and now Belgian citizenship. We are not married. Instead we have a registered partnership, which is common in northern Europe, confers most of the benefits of marriage, and raises no eyebrows. However, the American government does not recognize such partnerships so in their eyes I am still single.

Generally, children of American citizens abroad automatically become American citizens themselves at birth. But our kids fall under an exception. Male American citizens who live abroad and have children out of wedlock with a non-citizen mother do not automatically transmit citizenship to their children unless they sign an “affidavit of support” promising to support their children until the age of 18. If you don’t sign before the child reaches 18, the child is not considered an American citizen. This has been upheld by two Supreme Court rulings (Nguyen v. INS and Flores-Villar v. United States). For legal beagles, the relevant statutes are 8 U.S.C. 1401 and 1409.

The kids have Swedish and Belgian citizenship. We could go down to the American consulate and get American citizenship for them any time, but I keep putting off the decision and I am not sure I want to do it at all. Sentimentally I would like the kids to have American citizenship, but there is really only one practical pro to it:

* American citizenship would allow them to live, work, or study in America more easily, if they choose, when they get older.

The cons:

* They would be immediately enmeshed in the U.S. tax bureaucracy, which would require them to file U.S. tax returns for life even if they never set foot in the U.S. This, as I know from experience, is a huge bother, even when you don’t owe anything.
* Sometimes they would owe U.S. tax, though, for example for capital gains, unearned income, and in some countries self-employment income.
* My son would have to register for the draft.
* The decision, once made, is difficult to back out of: renouncing one’s U.S. citizenship costs $2300 and a lot of paperwork.
* They can easily travel to the US for family visits as Belgian/Swedish citizens.
* There are lots of good universities in Europe. And if they really wanted to study in the U.S., it’s not too hard to do as a European.

What do you think I should do? The clock is ticking, and I find it hard to choose between the evil of not being able to be American if they choose, and the evil of unjust, lifelong pursuit by the IRS.

Yours sincerely,
A loyal Slashdotter.

Here are two good relevant links:
https://americansabroad.org/is...
http://www.nytimes.com/2014/12...

Comment Re:Cause meet Effect. (Score 1) 47 47

Although ultimately you are right, there is a useful probabilistic approach to this besides considering the theoretical value of a position. Since chess is very far from being solved, you don't really know the theoretical value of very many positions. However, you can make models for the probability of the outcome from a position (a choice of an engine is such a model). A blunder is then a move that reduces the expected score for the player that made it, by some amount.

And as others have said, he should have used Stockfish.

Comment Re:Consciousness versus Intelligence (Score 1) 455 455

This position seems to be popular among people that don't know the first thing about AI. So let me explain the situation from a point of view familiar to AI practitioners: A rational agent is one that acts as if it were maximizing the expected value of some utility function. That, in a nutshell, is the core of making decisions under uncertainty, and the basic recipe for a large part of AI. As part of the design of a utility-centered AI system, you define the utility function, which is precisely how you would tell the machine what to want. None of this "boggles the mind". It is almost trivial, actually. The difficult parts are perception, how to model future events to evaluate the expected value of the utility function in different scenarios, etc.

Comment Re:Phooey. They Can Still Kill Us All (Score 1) 455 455

Don't worry. It is using a non-standard prototype for `main', and it forgot a few semicolons. It will stop working the next time the compiler is updated. Who knew that some obscure idiosyncrasies of the C programming language would save humanity? :)

Comment Re:Here comes a Karma hit.... (Score 1) 107 107

I was programming at her age (BASIC on some 8-bit computer), and I turned out OK. My parents weren't very happy that I spent many hours a day in front of the computer, but that's what allowed me to have a great job as an adult.

I would just let the girl do whatever she is interested in.

Comment Re:I'm not a scientist... (Score 4, Funny) 99 99

According to Anses, the process of assimilating a three-dimensional effect requires the eyes to look at images in two different places at the same time before the brain translates it as one image.

Isn't that how normal vision works anyway?

That's why France doesn't allow children under the age of six to open both eyes at the same time.

Comment A much simpler method (Score 5, Interesting) 93 93

If the only two choices are positive/negative (or thumbs up/thumbs down or some other equivalent 0/1 scheme), here's a formula that should work fairly well:

(n_positive + 1) / (n_positive + n_negative + 2)

So a single positive review gives you a score of .6667, and a single negative review gives you .3333. For large numbers of reviews, the score quickly converges to the actual fraction. If you don't have any reviews, you are at .5000.

The mathematical justification for this formula is that if you try to use a Bayesian approach to estimating the true probability of getting a positive review, and you start with a flat prior, this formula gives you the average of the posterior probability after observing the given number of positive and negative reviews. The full posterior distribution is a beta distribution with parameters alpha=n_positive+1 and beta=n_negative+1.

This formula is often used when applying Monte Carlo techniques to the game of go. I believe a lot of programmers simply start the counters of wins and losses at 1 to avoid corner cases (like division by 0), and they accidentally use the correct formula.

Comment Re:Question... -- ? (Score 1) 215 215

While that is indeed the solution, it is also true that it is too easy to forget. Perhaps one could modify all commands to require the use of the "--" separator, or to warn if it's not present, at least if some environment variable is set. That could be very helpful for people trying to write more secure code.

Comment Re:Good! (Score 1) 279 279

Please compare the supermarket shelves in the USA with those in Venezuela or North Korea and then come back here and tell me why big government controlling the means and distribution of production is a good idea, compared to the free market, with people providing each other with services in return for a token of exchange (currency).

I'm not saying that there isn't an element of truth in what you are saying, but you have to pick comparable countries or the comparison will mean nothing. So looking at North Korea versus South Korea is fine, as is comparing Venezuela to Colombia, or Cuba to Dominican Republic. If you want to compare the U.S. to anyone, perhaps Sweden would do. But Sweden is pretty darn nice. :)

Machines that have broken down will work perfectly when the repairman arrives.

Working...