Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The understanding of Unix philosophy

2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Unix philosophy is taken from simplicity in Linux programming (third Edition): many useful Unix tools are very simple and therefore small and easy to understand. "small and simple" is worth learning, larger and more complex systems are bound to contain larger and more complex bug, and debugging is something everyone wants to avoid. Concentration: in general, it is better to have a program perform a task well than to pile up all the functions in a mess. Functional swelling programs are difficult to use and maintain. Programs with a single goal are more likely to be improved as better algorithms or interfaces are developed. In UNIX, when users have new requirements, they usually combine gadgets to accomplish more complex tasks, rather than trying to put all the functions that a user might expect into one large program. Reusable components: implement the core of the application as a library. Libraries with simple and flexible programming interfaces and well-documented libraries can help others develop similar programs, or apply these technologies to new applications. Filters: many Unix programs can be used as filters. That is, they convert the input and produce the output. As we will see later, Unix provides mechanisms that allow us to combine some Unix programs in a novel way to develop fairly complex applications. Of course, the role of this type is supported by the previously mentioned development approach. Open file format: the more successful and popular Unix programs use plain ASCII text files as configuration files and data files. If you use this approach when developing programs, you are right! It enables users to modify and search configuration items with standard tools, and to develop new tools to perform new functions on data files. Flexibility: you can't expect users to use your program correctly. Therefore, when programming, we should try to take into account the flexibility of the program; try to avoid artificial restrictions on the length of fields or the number of records. If you can do it, the programs you write can run both on a stand-alone machine and across the network. Never think you know everything the user wants to do.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report