Re: [docs] See the changes for 23Sep2019

new topic     » goto parent     » topic index » view thread      » older message » newer message
ChrisB said...

Hi

So is it ok to edit these examples so that a copy paste actually produces a working example (where possible)?

Cheers

Chris

Please do so.

I strongly believe that all examples must run. The output should be shown. I use --> to show the output on the next line.

For a built-in:

puts(1, "hello") 
--> hello 

For a std/lib:

include std/console.e 
display( "hello" ) 
--> hello 

If you must provide a code snippet, make it clear it is incomplete:

 
-- ...  
 
atom fn = open( "data.txt" ) 
? results 
 
-- ... 
 

(Not sure if -- ... is the best visual clue; use something like it.)

_tom

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu