你见过(或写过)最美丽/最高质量的代码是什么?
我今晚有一个字面上的灵感,想到在工作中我们都不喜欢处理我们的 Helm 图表,因为它的语法和结构看起来太丑陋,感觉就是不对(更不用说在多个不同的管道中处理 Kubernetes 资源的多种不同方法)。
我努力超越对奇怪代码的初步排斥,因为我知道它可能非常实用。但这让我思考:什么才是美丽的代码?什么才是“高质量”的代码?(显然,除了它能生成一个有效、性能良好且稳健的软件程序之外)。
所以我很好奇——你能给我展示一下你遇到的最好的代码吗?可以是一小段代码,也可以是一个“库的切片”或架构等等。你自己写过什么让你特别自豪的东西吗?
查看原文
literal shower-thought i had tonight as i was thinking about how at work we all don't like dealing with our helm charts because the syntax and structure ends up looking so ugly and it just feels wrong (not to mention the multiple different approaches of handling kubernetes resources in multiple different pipelines.<p>i try to see beyond any initial repulsion to weird looking code because i know that it may be super functional. but it got me thinking: what makes code beautiful? what makes code "high quality"? (other than that it results in a working, performant, and robust software program obviously).<p>so i'm curious -- can you show me the best code you've encountered? it can be a small snippet or it can be a "slice of a library" or an architecture etc. have you written anything yourself that you are super proud of?