Studies on optimal code width?

前端 未结 11 651
滥情空心
滥情空心 2021-01-29 18:42

If you enable the \"View Right Margin\" in your IDE of choice, it is likely that it will default to 80 characters. I tend to change it to 120 for no reason other than it was th

11条回答
  •  伪装坚强ぢ
    2021-01-29 19:24

    Actually, the 80-column thing long precedes DOS. It comes from card punches, which were 80-column devices.

    And to kind of answer the OP's question, one "study" has been going on for about 600 years now - the printed book. These have evolved over the centuries, with readbility foremost in mind, to the position we are at now where the average line length for text is around 60 characters. So for readability, go for narrower margins.

提交回复
热议问题