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


Forgot your password?
DEAL: For $25 - Add A Second Phone Number To Your Smartphone for life! Use promo code SLASHDOT25. Also, Slashdot's Facebook page has a chat bot now. Message it for stories and more. Check out the new SourceForge HTML5 internet speed test! ×

Comment Jython, not JPython (Score 1) 129

Nitpicking, buy it was JPython in 1997
It has been Jython since 1999

> I do not know why anybody would even think of using a programming language without static typing.

- Dynamically typed programming languages are more productive when writing smaller quantities of rapidly evolving code.

- It is mainly a library and an ecosystem issue. Python tends to have all the modules I need, while Haskell, OCaml and Scala often don't... and they often seem to be much easier to pick up and use.

For example, Pandas equivalents are much less mature in other ecosystems. On language merits alone, I should be using Scala more than Python, but in practice, Python modules win me over.

I wanted to memoise a function. To look up a module and put in the couple of lines (an import and a decorator) needed to achieve that probably took a couple of minutes in Python, and I was back to the real meat of my code. I would have spent much longer in Java.

Comment Re:Welcome to India (Score 1) 96

Rapes in India: about 37,000 per year for a country of 1.26 BILLION. Press reports it as a rape every 20 min.
Rapes in US: 1,200,000 per year for a country the fourth of India according to CDC. No one talks about it.
Obviously, BOTH are under-reporting.
If you take a large country as India or China, every measure will be automatically large. Talking absolute numbers rather than per capita adjusted numbers is either dumb or malicious journalism. During the Delhi rape coverage, not one newspaper I read talked about per capita rates.

Let's be realistic. For a poor country, the rights of women in India are no worse than similar poor countries. At least in India, the public holds large protests over rape. Don't see that much elsewhere.

Comment Re:Alarmism (Score 2) 96

You are entirely looking at India with US legal system lenses. In India, the political system is not dominated by lawyers i.e. the politicians don't have a legal background as much as they do in US. Public prosecutors don't routinely run for elections and hence have an interest in promoting themselves as "tough on crime". AFAIK, terrifying the defendant with disproportionate punitive threats and forcing him/her into a plea deal is not an issue in India. There, the problems are more around the legal process taking simply too long due to inadequately funded institutions, outdated laws and generally a less agile system (poorer country), rather than an overzealous application.

That said, both India *and US* do have arbitrary application of law - due to different reasons and cause different sets of problems. Corruption is of course more in India, as you would expect in any country with its per capita income. Yet, I'd say that far... far more people are put in prison in US due to arbitrary application of law than in India, even though the due process is said to be much better in US.

Comment Alarmism (Score 4, Informative) 96

All this is pointless hyperventilating by people who understand little about India.
India is one the LEAST punitive countries in the world. It does not believe that putting people in the prison is a solution for anything – even for things most of us would agree that people should be put into prison for.
India’s incarceration rate is 33 (one of the lowest in the world) per 100,000
US incarceration rate is 698 (highest incarceration rate in the world, if you ignore Seychelles) per 100,000
Have you ever heard of anyone put in prison in India for downloading a file? The law has been around since 1957. I am not even sure if for-profit bootleggers who sell media in India have been in prison for more than a few weeks. This is just some tech-ignorant government bureaucrat getting carried away. If a 0.01% of Indians tweet about it, the warning will be edited to something realistic. This has been the pattern about most India alarmist articles on Slashdot.

Comment Re:Jingoism and Nativism (Score 0) 242

If you think not letting Apple open a few stores, unless they sell a few goods from India in return, is comparable to the utter and complete destruction of an entire civilization's economic status in the world during the colonial era, in the guise of free (which it was not) markets, you are completely unread of world history outside the western perspective, if not the remnants of the cold-war era propaganda perspective, that too in a rather shallow sense. This has nothing to do with Trump or whatever is his message. I am talking history, and its consequences on policy, not pandering politics and demagogues. Read at least one book on the devastation of colonialism and force-imposed free trade on India. Until you do, you won't get this. Yes, I can hear myself talk; not sure you can.

Comment Re:Jingoism and Nativism (Score 5, Insightful) 242

You are ignoring the fact that India was colonized and used as nothing but as a market for centuries and sucked dry. Those scars will take a long while to heal and those are lessons not easily forgotten. The word "Free Trade" has a different meaning to an Indian (as well as to those who also endured the Opium Wars and the Black Ships incident in their history). They had completely different experiences with it in their history. This is a rational strategy from those experiences.

Likewise the idea of protectionism has cold war era connotations in US; not so in India. It was a necessarily strategy for India to protect itself from neo-colonialism when its capacity to compete was never allowed to mature. India started rolling back these defenses (which naturally hold back growth - security vs. speed) gradually once it felt its industries and services are maturing and have a chance to actually compete in a free market. But that is a gradual process rather than a binary choice.

> Why should the people of one country be privileged over the people of any other? Just because they were born there?

That said, I generally agree with the sentiment. But even the majority in US don't agree with that.

Comment Re:Thought he retired... (Score 2) 257

This is a simple general rule: When someone merely points to the expert consensus (with respect to any mainstream science), without any innovation, they do not need to be challenged on their personal expertise. People who do refute an expert consensus are those who need to be challenged on their expertise and are asked to submit their evidence to peer review.

I don't need to be a biologist to say that evolution is real. If I say it isn't, THEN my credentials come into question.

Comment The risks of extrapolating (Score 1) 830


There are logical fallacies here. If we can simulate something in "some" way, we do not necessarily have to assume that we will eventually end up with perfect simulations, even with infinite time. Or that ever growing size of simulations will have to necessarily culminate in universe scale simulations. This optimism is along the idea of Victorian assumptions of progress or along the lines of Cartesian optimism before it was tempered with Lockean empiricism. There will usually be previously unanticipated hard stops... like the speed of light.

Tyson is obviously a master of his subject and I am not a physicist and I don't understand these simulation theories in their native form. But this summary makes it sound like we are getting ahead of ourselves with assumptions.

Comment Re:This JVM stuff is BS (Score 1) 121

> Indentation weakens the language.

The goal of a syntax is to, first and foremost, promote human readability. Python philosophy is to discourage clever code. Many, like myself, find consistent indentation and low character noise to be more readable. If you don't, that's fine. It is a preference. If you like complete flexibility, go with Lisp (or Hy in Python), since its minimal syntax gives maximal power of expression - we all should, if it was all about power. But we don't. I prefer reading Python than Lisp, most of the time. We all like a balance between a helpful syntax and maximal expressive power. Where we individually draw the line differs.

> Everyone formats their code but forcing it makes for a less powerful language, so why do such idiocy?

It's not idiocy; it was clever and it was a well-considered choice. We already indent anyway. So why not codify that into syntactic rules, thereby making the language more clean to read? Python tries to get rid of needless punctuation. We write single line expressions/statements most of the time. So Python (and many others) makes them the default by making the semi-colon optional and instead provides a back-slash if you want multi-line code.

I used/tried every major modern language. I find Python to be the simplest and cleanest to read (many functional languages do a good job as well). That's a preference of course. I like Boo over C# because it has a Python-like indentation syntax. YMMV.

Nimrod, Delight, Converge and Cobra are other lesser known programming languages that use indentation syntax. Haskell uses it to some degree.

When I first saw Python and indentation syntax some 15 years ago, I thought: How clever... and immediately got used to it. Some don't and never get over it. Some get the same feeling with Lisp, but I didn't, even though I acknowledge the arguments. It's a preference.

Comment Re:This JVM stuff is BS (Score 1) 121

I think everyone learns quickly to pay attention to indentation settings in Python. I make sure that mine converts tabs to spaces and that tabs are always visible so that there is no trip up when editing code from other people. I use autoformat a lot in languages like Java but don't in Python. So I never ran into that problem. Since one does frequent runs with Python code, my editor just saves whenever I hit run. So I never needed a separate timed (if that is what you meant) autosave.

Slashdot Top Deals

Contemptuous lights flashed flashed across the computer's console. -- Hitchhiker's Guide to the Galaxy