Difference between revisions of "Writestring"
From Mesham
Jump to navigationJump to search (Created page with '== Overview == This writesmring[f,a] function will write the value of ''a'' to the file denoted by handle ''f''. * '''Pass:''' The File handle to write to and the [[String]…') |
m (4 revisions imported) |
||
| (3 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
== Overview == | == Overview == | ||
| − | This | + | This writestring(f,a) function will write the value of ''a'' to the file denoted by handle ''f''. |
* '''Pass:''' The [[File]] handle to write to and the [[String]] to write | * '''Pass:''' The [[File]] handle to write to and the [[String]] to write | ||
| Line 9: | Line 9: | ||
#include <io> | #include <io> | ||
| − | var f:=open("hello.txt","w"); | + | |
| − | + | function void main() { | |
| − | + | var f:=open("hello.txt","w"); | |
| + | writestring(f,"hello - test"); | ||
| + | close(f); | ||
| + | }; | ||
| + | |||
| + | ''Since: Version 0.41b'' | ||
[[Category:Function Library]] | [[Category:Function Library]] | ||
[[Category:IO Functions]] | [[Category:IO Functions]] | ||
Latest revision as of 15:44, 15 April 2019
Overview
This writestring(f,a) function will write the value of a to the file denoted by handle f.
Example
#include <io>
function void main() {
var f:=open("hello.txt","w");
writestring(f,"hello - test");
close(f);
};
Since: Version 0.41b