[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
##############################################################################
###+---------+################################################################
#+-| SPACE() |------------------------------------------------------+#########
#| +---------+ Returns a string of length size that is blank filled |#########
#+------------------------------------------------------------------+#########
##############################################################################
##############################################################################
#+--| Summary |----------------+##############################################
#| #INCLUDE string.hdr |##############################################
#+-----------------------------+##############################################
##############################################################################
##############################################################################
#+--| Syntax |---------------------------+####################################
#| FUNCTION CHAR space PROTOTYPE |####################################
#| PARAMETERS VALUE UINT size |####################################
#+---------------------------------------+####################################
##############################################################################
##############################################################################
##################+---| Description |---------------------+###################
##################| The space() function returns a string |###################
##################| of length size that is blank filled. |###################
##################+---------------------------------------+###################
##############################################################################
##############################################################################
#########+--| Example 1 |-------------------------------------------+#########
#########| |#########
#########| z = space(50) && Prints "50" |#########
#########| ? zen(z) && Prints 50 spaces |#########
#########| z + "end of string" && then the string. |#########
#########+----------------------------------------------------------+#########
##############################################################################
##############################################################################
#########+--| Example 2 |-------------------------------------------+#########
#########| * A "center()" function. |#########
#########| |#########
#########| FUNCTION CHAR center |#########
#########| PARAMETERS CONST CHAR c, VALUE INT i |#########
#########| VARDEF |#########
#########| INT k |#########
#########| ENDDEF |#########
#########| |#########
#########| k = i - len( c ) |#########
#########| RETURN space( k ) + c + space( k ) |#########
#########| ENDPRO |#########
#########+----------------------------------------------------------+#########
##############################################################################
See Also:
stuff()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson