logoalt Hacker News

squeaky-cleantoday at 5:53 AM1 replyview on HN

Which of these programs is easier to review

  {x{x,sum -2#x}/0 1}
or

  def f(n):
      if n <= 1:
          return n
      else:
          return f(n-1) + f(n-2)
They're both the same program

Replies

jimbokuntoday at 12:26 PM

Good question.

But it is orthogonal to the question of evaluating 2000 lines of AI code vs 200 lines of human written code. Either the human or the AI could produce idiomatic code for either language, given sufficient training data in the AI’s corpus for the language.

My guess is that the first one is much quicker to review, for a human equally fluent in both languages.