Core Function BinaryCompare

From Sputnik Wiki
(Difference between revisions)
Jump to: navigation, search
UberFoX (Talk | contribs)
(Created page with "<pre> BinaryCompare( <binary-array>, <binary-array2> ) </pre> === Description === Compare two binary variables. === Parameters === ==== binary-array ==== The a binary variab...")
Newer edit →

Revision as of 07:07, 26 April 2012

BinaryCompare( <binary-array>, <binary-array2> )

Contents

Description

Compare two binary variables.

Parameters

binary-array

The a binary variable to use.

binary-array2

The a binary variable to use.

Return Value

Success: Returns 1.

Failure: Returns 0.

Remarks

None.

Example

my $Binary1 = Pack("z0", "Hello world!!!");
my $Binary2 = Pack("z0", "Hello world!!!");
 
If( BinaryCompare($Binary1, $Binary2) )
{
	println("Both binary variables contain the same data");
}
Else
{
	println("No match");
}
 
println("");
println("Lets try again now now that one was changed");
my $Binary1 = Pack("z0", "Test");
If( BinaryCompare($Binary1, $Binary2) )
{
	println("Both binary variables contain the same data");
}
Else
{
	println("No match");
}
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox