Skip to main content
fix ruby syntax. Too many languages!
Source Link
kevin cline
  • 33.7k
  • 3
  • 72
  • 142

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p ->|p| p.height > 200 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p -> p.height > 200 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { |p| p.height > 200 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

edited body
Source Link
kevin cline
  • 33.7k
  • 3
  • 72
  • 142

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p -> p.height > 2.0200 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p -> p.height > 2.0 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p -> p.height > 200 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

added 587 characters in body
Source Link
kevin cline
  • 33.7k
  • 3
  • 72
  • 142

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p -> p.height > 2.0 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

I am much more productive in more powerful languages like Python or Ruby. It doesn't matter if some of the Java code can be generated by an IDE. There is more code to read and maintain. It takes more time to wade through repetitive code and find the important parts, and more time to change it. It's fine that Eclipse can convert

private Date dateOfBirth;

to:

private Date dateOfBirth;
public Date getDateOfBirth() { return dateOfDeath; }
public setDateOfBirth(Date d) { dateOfBirth = d; }

but every time I open the class I will see that junk and have to skim past it to find the interesting parts. Also, during maintenance, errors can be introduced into generated code.

I would much rather see:

attr :date_of_birth

To me, the need for an IDE to work effectively with Java is a good reason to choose another language.

Perhaps more powerfully, compare this Ruby code:

avg = people.filter { p -> p.height > 2.0 }.collect(:weight).average

against similar Java code:

List<Double> weights = new ArrayList<Double>();
for (Person p: people) {
  if (p.getHeight() > 200) {
    weights.add(p.getWeight());
  }
}
return Stats.average(weights);

The Ruby code is a direct translation of the specification: the average weight of people taller than 200 (cm). A comment would be utterly redundant.

The Java code requires considerable work to both write and read.

Paul Graham makes a convincing argument for brevity in programming languages in this essay. Having done some graduate level mathematics, I find his argument compelling, and the arguments against brevity weak. Certainly a single line in a high level language may be harder to understand than a single line in a low level language, just as a partial differential equation is harder to comprehend than a simple addition. But a single line in a powerful language is easier to comprehend than the five or ten lines it replaces. Imagine reading a math text that was written using words instead of symbols.

added 657 characters in body
Source Link
kevin cline
  • 33.7k
  • 3
  • 72
  • 142
Loading
Source Link
kevin cline
  • 33.7k
  • 3
  • 72
  • 142
Loading