This wiki is out of date, use the continuation of this wiki instead

String

From FenixWiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 14:52, 1 August 2007 (edit)
Sandman (Talk | contribs)
m
← Previous diff
Current revision (14:44, 20 February 2008) (edit) (undo)
Sandman (Talk | contribs)
m (Example)
 
(4 intermediate revisions not shown.)
Line 5: Line 5:
'''STRING''' '''STRING'''
-'''String'''s are a sort of character array, combining characters to form text. Because the length of a '''string''' is dynamic, adding them is done easily. The quotes can be used to create strings.+'''String'''s are a sort of character array, combining characters to form text. Because the length of a '''string''' is dynamic, adding them is done easily. Single and double quotes can be used to create strings.
== Example == == Example ==
Line 17: Line 17:
surname = "Momma"; surname = "Momma";
- say(name + " " + surname + "has entered.");+ say(name + " " + surname + " has entered.");
 + say('User logged on: "' + name + " " + surname + '"');
- Loop+ Repeat
frame; frame;
- End+ Until(key(_ESC))
 + 
End End
</pre> </pre>
 +Used in example: [[say]](), [[key]]()

Current revision


[edit] Definition

STRING

Strings are a sort of character array, combining characters to form text. Because the length of a string is dynamic, adding them is done easily. Single and double quotes can be used to create strings.

[edit] Example

Program strings;
Private
    String name;
    String surname;
Begin
    name = "Yo";
    surname = "Momma";

    say(name + " " + surname + " has entered.");
    say('User logged on: "' + name + " " + surname + '"');

    Repeat
        frame;
    Until(key(_ESC))

End

Used in example: say(), key()

Personal tools