Hello world/Line printer: Difference between revisions
Content added Content deleted
Line 478: | Line 478: | ||
# ^ The prefix "." says "use the default device here" |
# ^ The prefix "." says "use the default device here" |
||
}</lang> |
}</lang> |
||
=={{header|Phix}}== |
|||
If you have not got something appropriate attached, this will just hang. Other values you can try, on windows: "AUX", "COM1", "COM2", "LPT1" |
|||
<lang Phix>integer fn = open(iff(platform()=WIN32?"PRN":"/dev/lp0"),"w") |
|||
if fn=-1 then |
|||
puts(1,"some error") |
|||
else |
|||
puts(fn,"Hello World!") |
|||
close(fn) |
|||
puts(1,"success!") |
|||
end if |
|||
{} = wait_key()</lang> |
|||
=={{header|PHP}}== |
=={{header|PHP}}== |