Difference between revisions of "Write"
From Free Pascal wiki
Jump to navigationJump to search (syntaxhighlight) |
|||
Line 5: | Line 5: | ||
<syntaxhighlight> | <syntaxhighlight> | ||
− | + | var | |
+ | a, b: Integer; | ||
begin | begin | ||
− | + | a:=42; | |
− | Write(' | + | b:=23; |
− | + | Write('a=', a, ' and b=', b); | |
end | end | ||
</syntaxhighlight> | </syntaxhighlight> | ||
− | prints | + | prints `a=42 and b=23` |
− | + | ||
+ | |||
+ | Parameters must be separed by a [[,]]. | ||
+ | |||
+ | WriteLn [[writeln]] behaves just like Write, except it leaves a newline character after the text. | ||
[[Category:Pascal]] | [[Category:Pascal]] |
Revision as of 16:18, 5 August 2014
│
Deutsch (de) │
English (en) │
español (es) │
русский (ru) │
write is a keyword which indicates some characters to put on the screen for example
var
a, b: Integer;
begin
a:=42;
b:=23;
Write('a=', a, ' and b=', b);
end
prints `a=42 and b=23`
Parameters must be separed by a ,.
WriteLn writeln behaves just like Write, except it leaves a newline character after the text.