Tip of the week - multilines and 4.0

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

This weeks Tip of the week brought to us by Jeremy Cowgar

In 4.0 you now have the ability to use two main multi-line features: Strings and Comments.

-- Comment out a block of code in 4.0: 
/* 

procedure say_hello(sequence name) 
   printf(1, "Hello, %s!", { name }) 
end procedure 
*/ 

Anything in between /* and */ is considered a comment.

Multiline strings are also in 4.0:

sequence emailMessage = """ 

Dear %s, 
 
I hope this email finds you well. 
 
%s""" 
 
printf(1, emailMessage, { "John Doe", "Euphoria Team" }) 

There is much more to multiline strings. See the manual, man:lang_def.html#characterstringsandindividualcharacters for more information on Character Strings.

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

Search



Quick Links

User menu

Not signed in.

Misc Menu