找回密码
 注册

微信登录

微信扫一扫,快速登录

萍聚头条

查看: 312|回复: 0

【经济学人精读】AI code is simpler, but not better |AI代码更简单,但并非更好

[复制链接]
发表于 2025-9-14 19:54 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?注册 微信登录

×
作者:微信文章
w1.jpg
扫码订阅专栏,即刻解锁500+篇精选文章~

精读文本

Programmers increasingly use artificial-intelligence tools to write code for software. But is it any good? A recent study by researchers at the University of Naples Federico II suggests not. The researchers compared more than 500,000 software functions written in Python and Java, two popular programming languages. Humans wrote some of the samples; popular AI models such as ChatGPT, DeepSeek-Coder and Qwen created the rest.

The scientists found that AI tends to write shorter, simpler programs. But its output was riddled with errors and showed more serious security weaknesses, particularly in Java. The identified vulnerabilities were serious: they could have allowed hackers to insert nefarious commands at an operating-system level, or left credentials such as usernames and passwords unprotected. In contrast, the human-written code was more complex, making it less vulnerable to hackers but harder to troubleshoot. The researchers suggested that AI coders can be useful—but only with a rigorous check.

生词


    sample /ˈsæmpl/ (n.): 样本;样品

    output /ˈaʊtpʊt/ (n.): 输出;产出

    riddled with /ˈrɪdld wɪð/ (phr.): 充满…(尤指坏事)

    vulnerability /ˌvʌlnərəˈbɪləti/ (n.): 漏洞;脆弱性

    hacker /ˈhækər/ (n.): 黑客

    nefarious /nɪˈfeəriəs/ (adj.): 邪恶的;不法的

    command /kəˈmænd/ (n.): (计算机)命令

    operating-system /ˈɒpəreɪtɪŋ sɪstəm/ (n.): 操作系统

    credential /krəˈdenʃl/ (n.): (常作复数)凭证,证件(如用户名、密码)

    troubleshoot /ˈtrʌblʃuːt/ (v.): 排除故障;解决难题

    rigorous /ˈrɪɡərəs/ (adj.): 严格的;严谨的
概括

一项新研究发现,虽然人工智能生成的代码比人类编写的更简洁,但却充满了更多错误和严重的安全漏洞。研究人员因此建议,AI编码工具虽有用,但其产出必须经过人类程序员的严格检查。
文章解析


    But is it any good?: 这是一个非常口语化的设问。“Any good” 是 “good” 的一种强调形式,常用于疑问句和否定句中,意思是“究竟好不好”。这个问题引导读者进入文章的主题,即对AI生成代码质量的探讨。 例句:I've heard a lot about that new restaurant, but is the food any good? (我听说了很多关于那家新餐厅的事,但它的菜到底好不好吃?)

    its output was riddled with errors: “Be riddled with” 思是“充满了(不好的东西),满是”,就像某样东西被子弹打得千疮百孔一样。用在这里生动地描绘了AI代码中错误和漏洞之多。 例句:The old ship's hull was riddled with rust and holes. (那艘旧船的船体上满是铁锈和破洞。)

    nefarious commands: “Nefarious” 是一个较为正式和强烈的词,意为“极度邪恶的,不道德的,非法的”,比 “bad” 或 “malicious” 更具文学色彩和严重性。用它来形容黑客植入的命令,强调其潜在的巨大危害。 例句:The villain in the movie had a nefarious plan to take over the world. (电影中的反派有一个接管世界的邪恶计划。)

    less vulnerable to hackers but harder to troubleshoot: 这个 “less... but harder...” 的对比结构清晰地阐述了人类编写代码的两个对立面:复杂性带来了更高的安全性(优点),但也导致了维护困难(缺点)。 例句:This car is safer in a crash, but more expensive to repair. (这款车在碰撞时更安全,但维修费用也更贵。)

    with a rigorous check: “Rigorous” 意为“严格的,严谨的,一丝不苟的”。“With a rigorous check” 指在使用AI代码前,必须经过非常仔细和严格的人工审查。 例句:All new medicines must undergo rigorous testing before they are approved for public use. (所有新药在获准供公众使用前,都必须经过严格的测试。)
翻译

程序员们正越来越多地使用人工智能工具来编写软件代码。但这些代码到底好用吗?那不勒斯腓特烈二世大学研究人员最近的一项研究表明,并非如此。研究人员比较了超过50万个用两种流行编程语言——Python和Java——编写的软件函数。其中一些样本由人类编写;其余的则由ChatGPT、DeepSeek-Coder和Qwen等流行的AI模型创建。

科学家们发现,AI倾向于编写更短、更简单的程序。但其输出内容却充满了错误,并显示出更严重的安全弱点,尤其是在Java代码中。所发现的漏洞都很严重:它们可能允许黑客在操作系统层面插入恶意指令,或者让用户名和密码等凭证处于未受保护的状态。相比之下,人类编写的代码更为复杂,这使其更不容易受到黑客攻击,但也更难以排查故障。研究人员认为,AI编程工具有其用武之地——但前提是必须经过严格的审查。
练习


    What is the primary conclusion of the study conducted at the University of Naples Federico II?

    (A) That AI-generated code is significantly more efficient and easier to maintain than human-written code.

    (B) That AI and human programmers produce code of a nearly identical quality and complexity level.

    (C) That AI-generated code, while simpler, is more prone to errors and security flaws than human code.

    (D) That Java is a more suitable programming language for AI code generation than Python is.

    According to the passage, what was identified as a major problem with the code produced by AI models?

    (A) It was generally more complex and difficult for human programmers to troubleshoot.

    (B) It required significantly more computing power to run and execute efficiently.

    (C) Its output contained a higher number of errors and more severe security vulnerabilities.

    (D) It was often too lengthy and overly complicated for the simple tasks it was designed for.

    How does the passage characterize the human-written code that was analyzed in the study?

    (A) Its greater complexity made it more difficult to troubleshoot but less susceptible to hackers.

    (B) It was found to be much shorter and simpler than the code generated by the AI models.

    (C) It contained a surprisingly high number of unprotected usernames and passwords.

    (D) It was particularly weak in the Java programming language, showing numerous security flaws.



扫码订阅专栏,即刻解锁500+篇精选文章~

扫描二维码申请加群,可获得问题答案😊



Die von den Nutzern eingestellten Information und Meinungen sind nicht eigene Informationen und Meinungen der DOLC GmbH.
您需要登录后才可以回帖 登录 | 注册 微信登录

本版积分规则

Archiver|手机版|AGB|Impressum|Datenschutzerklärung|萍聚社区-德国热线-德国实用信息网

GMT+2, 2025-9-19 20:45 , Processed in 0.135959 second(s), 30 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2025 Discuz! Team.

快速回复 返回顶部 返回列表