Basic Pascal Tutorial/Hello, World/zh CN
한국어 · Deutsch · English · Español · Français · Italiano · Svenska · Български · Русский · العربية · 中文(中国) · 日本語
Hello, World (原作者: Tao Yue, 状态: 未更改)
在计算机程序设计不长的历史中,一个经久不衰的传统就是学一门新语言的时候的第一个程序是显示一个"Hello, world"到屏幕上。所以我们开始吧!复制粘贴下面的程序到你的IDE或者文本编辑器中,然后编译并运行它。
如果你不知道怎么做,返回到目录表。上一页的课程讲解了编译器的作用,给出了可以下载的编译器的链接,还教你在Windows系统上安装了一个开源Pascal编译器。
program Hello;
begin
writeln ('Hello, world.')
end.你屏幕上的输出应该像这样:
Hello, world.如果你正在一个IDE中运行程序,你可能只看到程序一闪而过,在你看清结果之前又回到了IDE。如果不知道原因,请参见上一页的底部。一个建议的解决办法是,添加一个readln让程序在结束之前等待你按回车键,把"Hello, world"程序改成这样:
program Hello;
begin
writeln ('Hello, world.');
readln
end.| 上一页 | 目录 | 下一页 |
From the Free Pascal wiki, page "Basic Pascal Tutorial/Hello, World/zh CN", as it stood on 2022-08-20 after a change by Kai Burghardt, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.
Edited on wiki.freepascal.org by 4 people, 2013–2022
From the official wiki's backup of 26 May 2024: who edited this page there, and when. Edits made there after that date were not recorded, and the earlier versions are not shown here; the main page says why.
| When | Who | What changed |
|---|---|---|
| Memo | Translated this page into simplified Chinese. | |
| Memo | moved Hello, World/zh-CN to Hello, World/zh CN: Modified the title from "zh-CN" to "zh_CN" (minor) | |
| FTurtle | ||
| Trev | Fixed syntax highlighting; deleted category included in page template (minor) | |
| Kai Burghardt | Kai Burghardt moved page Hello, World/zh CN to Basic Pascal Tutorial/Hello, World/zh CN: tidy up main name space: create subpage hierarchy for basic Pascal tutorial [cf. [[Special: PermaLink/149778... (minor) | |
| Kai Burghardt | bypass redirects [cf. discussion] | |
| Kai Burghardt | bypass [previously missed] redirect [cf. discussion] | |
| Kai Burghardt | bypass language bar/categorization template redirect [cf. discussion] (minor) |
Talk about this page
Nobody has opened a bench for this page yet. Sign in to open one.
