# 四.教程

[快速入门](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/yi-kuai-su-ru-men)简单介绍了创建和部署新项目的基本工作流程，而无需探索项目目录或示例代码的内容。

接下来，我们将探索编写一些简单的程序，为您提供创建在 Internet Computer上运行程序的实践经验。

|   | 这些教程中的大多数说明了如何使用 Motoko 编程语言编写程序。 有关用其他语言编写的程序的其他示例，请参阅  DFINITY [examples](https://github.com/dfinity/examples) repository。 |
| - | ---------------------------------------------------------------------------------------------------------------------------- |

以下教程介绍了编写在 Internet Computer上运行的程序的基础知识：

* [探索默认项目](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/1.-tan-suo-mo-ren-xiang-mu) 通过探索创建新项目时添加到工作区的默认文件和目录，更深入地了解创建项目的工作流程。
* [使用Actor查询](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/2.-shi-yong-actor-cha-xun) 突出显示了如何通过定义一个带有 hello 函数的 actor（对象）来替换通常的“Hello, World!”中典型打印函数。
* [传递文本参数](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/3.-chuan-di-wen-ben-can-shu) 介绍了使用终端 shell 中的命令行将参数传递给函数的不同方式。.
* [自然数自增](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/4.-zi-ran-shu-zi-zeng) 指导您完成编写一个带有增加和返回数值函数的actor的程序。
* [计算函数中使用整数](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/5.-ji-suan-han-shu-zhong-shi-yong-zheng-shu) 向您展示如何编写一个简单的计算器程序，以便更多地练习使用 Motoko，并了解有关如何自定义项目环境的更多信息。
* [库模块导入](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/6.-ku-mo-kuai-dao-ru) 说明了如何导入和使用一些基本的 Motoko 基础库函数来处理列表中的键值对。
* [使用多个Actor](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/7.-shi-yong-duo-ge-actor) 描述了如何在单个项目中包含多个不相关的Actor，以说明如何为同一项目编译多个Canister。
* [自定义前端](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/8.-zi-ding-yi-qian-duan) 说明使用简单的 React 框架为默认示例程序创建新的前端，并指导您完成一些基本修改以自定义显示的界面。 如果您已经知道如何使用 CSS、HTML、JavaScript 和 React 或其他框架来构建您的用户界面，则可以跳过本教程。
* [添加前端样式](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/9.-tian-jia-qian-duan-yang-shi) 说明了在使用 React 为项目创建新前端时如何添加样式。 如果您已经知道如何向 React 添加样式，则可以跳过本教程。
* [调用其它Canister](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/10.-shi-yong-si-you-canister-tiao-yong) 说明了如何在同一项目中一个容器对另一个容器中定义的函数进行简单调用。
* [创建可扩展App](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/11.-chuang-jian-ke-kuo-zhan-app) 描述了使用多个Canister来创建可扩展的应用程序。
* [添加访问控制](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/12.-tian-jia-fang-wen-kong-zhi) 描述了如何创建和切换多个用户身份。
* [从钱包接受Cycles](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/si-.-jiao-cheng/13.-cong-qian-bao-jie-shou-cycles) 说明了如何接受从默认钱包canister发送的cycles。

[示例库](https://github.com/dfinity/examples)和 [Motoko 编程语言](https://app.gitbook.com/@dfinityteam/s/dfinity-tutorials-ch/~/drafts/-MavVrYR4hD4KJbu_nu-/liu-yu-yan/motoko-bian-cheng-yu-yan)中提供了其他教程，涵盖更高级的程序和有关如何使用基本构建块的更详细示例。


---

# Agent Instructions: 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:

```
GET https://mixdao.gitbook.io/dfinity/si-.-jiao-cheng.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
