Core Function BinaryCreate
From Sputnik Wiki
(Difference between revisions)
(→Example) |
(→Return Value) |
||
Line 23: | Line 23: | ||
Success: Returns the new binary variable. | Success: Returns the new binary variable. | ||
− | Failure: Returns | + | Failure: Returns null. |
=== Remarks === | === Remarks === |
Revision as of 14:36, 29 August 2013
BinaryCreate( <size>, <fill> )
Contents |
Description
Create a new binary variable and its array size and fill data type.
Parameters
size
The size (in bytes) of the new binary variable.
fill
Optional; The byte to fill the data with.
Default is 0
Return Value
Success: Returns the new binary variable.
Failure: Returns null.
Remarks
N/A
Example
$binary = BinaryCreate(1000); // Create it // Print its data $k = 0; Foreach ($binary as $i) { println( DecPad($k, 5) . " Byte: " . $i ); $k++; } // Finally print its size println("The size of the new binary variable is: " . BinaryLen($binary) );