> For the complete documentation index, see [llms.txt](https://go.netdpi.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://go.netdpi.net/next/14.01-yue-du-da-shi-zuo-pin.md).

# 14.01-閱讀大師作品

若要成為一個好的藝術者或作家，至少都要研究大師的作品。這點在程式設計也是一樣的。要成為技術高超的程式設計師，其中一個最佳的方式就是研究別人撰寫的程式原始碼。Go 語言非常適任，因為整個專案（project）的程式原始碼都可以自由免費取得。

例如，我們可能想要看看 `io/ioutil` 函式庫的程式碼，則可以參考：

[http://golang.org/src/pkg/io/ioutil/ioutil.go](https://web.archive.org/web/20200228062158/http://golang.org/src/pkg/io/ioutil/ioutil.go)

慢慢地謹慎閱讀程式碼，並試著了解每一行程式的意義並閱讀註解。例如，在 `ReadFile` method 中，有一行註解的內容如下所示：

```
// It's a good but not certain bet that FileInfo
// will tell us exactly how much to read, so
// let's try it but be prepared for the answer
// to be wrong.
```

這個 method 或許起初設計時比現在簡單許多。這是一個很棒的範例，可以知道程式如何在經過測試之後改進，以及為何對那些改變撰寫註解是很重要的。每個 packages 的程式碼都可以在此網址取得：

[http://golang.org/src/pkg/](https://web.archive.org/web/20200228062158/http://golang.org/src/pkg/)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://go.netdpi.net/next/14.01-yue-du-da-shi-zuo-pin.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
