Lecture

How do you write maintainable and readable code?

이 질문은 장기적인 협업과 코드 품질에 대한 인식, 그리고 문서화, 네이밍, 모듈화 등에 대한 습관을 평가합니다.

글로벌 기업에서는 협업과 코드 리뷰 문화가 강하기 때문에, 타인이 이해하고 수정하기 쉬운 코드를 얼마나 의식하며 작성하는지가 중요한 포인트입니다.


Answer 1: Practical habits and consistency

English

To write maintainable code and readable code, I follow a few core practices. First, I try to use clear and consistent naming — for variables, functions, and file structures. Good naming alone can reduce the need for extra comments.

Second, I break logic into single-purpose functions, which makes the code easier to test and refactor. I also write comments when the intention isn’t obvious from the code itself, but I avoid overcommenting.

Lastly, I always try to follow the team’s coding conventions and use tools like linters and formatters to ensure consistency. I believe consistency is just as important as cleverness in making code maintainable in the long run.

한국어 번역

유지보수하기 쉬운 코드읽기 쉬운 코드를 작성하기 위해 저는 몇 가지 핵심 원칙을 따릅니다. 먼저, 변수, 함수, 파일 구조에서 명확하고 일관된 네이밍을 사용하려고 노력합니다. 이름만 잘 지어도 주석이 덜 필요해집니다.

또한 로직을 하나의 역할만 수행하는 함수로 나누어 작성합니다. 이렇게 하면 테스트나 리팩터링이 쉬워집니다. 의도가 명확하지 않을 때는 주석을 작성하되, 과도한 주석은 피합니다.

마지막으로, 팀의 코딩 규칙을 따르고, 린터나 포매터를 활용해 코드의 일관성을 유지합니다. 장기적으로 유지보수가 쉬운 코드를 위해서는 창의성 못지않게 일관성이 중요하다고 생각합니다.

주요 표현 정리

  • maintainable code: 유지보수하기 쉬운 코드
  • readable code: 읽기 쉬운 코드
  • clear and consistent naming: 명확하고 일관된 네이밍
  • single-purpose functions: 하나의 역할만 수행하는 함수
  • coding conventions: 코딩 규칙
  • consistency: 일관성

Answer 2: Empathy and team-oriented mindset

English

For me, writing maintainable code and readable code means writing for the next person who will read or edit it — whether that's a teammate or my future self. I try to write code with empathy for other developers.

This means using descriptive variable names, avoiding overly clever shortcuts, and organizing the project structure to make things easy to find. When the business logic isn’t obvious, I add comments to explain the intent.

I also take feedback seriously during code reviews and view clean code as a result of continuous improvement, not a one-time effort.

한국어 번역

저는 유지보수하기 쉬운 코드와 읽기 쉬운 코드를 작성한다는 것은, 그것을 읽고 고칠 사람을 위한 코드라고 생각합니다. 그래서 항상 다른 개발자를 배려하는 마음으로 코드를 작성하려고 합니다.

이를 위해 의도가 잘 드러나는 변수명을 사용하고, 과도하게 영리한 축약은 피합니다. 또한, 프로젝트 구조를 명확하게 구성하여 전체 흐름을 쉽게 파악할 수 있도록 합니다. 비즈니스 로직이 명확하지 않은 부분은 주석을 통해 의도를 설명합니다.

코드 리뷰에서 받은 피드백은 진지하게 반영하고, 깨끗한 코드는 일회성이 아니라 지속적인 개선의 결과라고 믿습니다.

주요 표현 정리

  • write code with empathy: 다른 개발자를 배려하며 코드를 작성하다
  • descriptive variable names: 의도가 잘 드러나는 변수명
  • overly clever shortcuts: 과도하게 영리한 축약
  • project structure: 프로젝트 구조
  • continuous improvement: 지속적인 개선

Lecture

AI Tutor

Design

Upload

Notes

Favorites

Help

How do you write maintainable and readable code?