<Comment>/* The below does not represent a functional lock/unlock script.</Comment><br/>
<Comment> * It is intended to test KDE's Syntax Highlighting framework.</Comment><br/>
<Comment> */</Comment><br/>
<Normal Text></Normal Text><br/>
<Comment>// Pragma comment.</Comment><br/>
<Keyword>pragma</Keyword><Normal Text> </Normal Text><Built-in>cashscript</Built-in><Normal Text> ^0.9.2;</Normal Text><br/>
<Normal Text></Normal Text><br/>
<Comment>// Locking Script/Function.</Comment><br/>
<Control Structures>contract</Control Structures><Normal Text> TestContract</Normal Text><Symbol>(</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>address</Data Type><Normal Text> addressExampple</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>int</Data Type><Normal Text> intExample</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>bool</Data Type><Normal Text> boolExample</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>string</Data Type><Normal Text> stringExample</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>pubkey</Data Type><Normal Text> pubkeyExample</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>sig</Data Type><Normal Text> sigExample</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>	</Normal Text><Data Type>datasig</Data Type><Normal Text> datasigExample</Normal Text><br/>
<Symbol>)</Symbol><Normal Text> </Normal Text><Symbol>{</Symbol><br/>
<Normal Text>	</Normal Text><Comment>// Unlocking Script/Function.</Comment><br/>
<Normal Text>	</Normal Text><Control Structures>function</Control Structures><Normal Text> testUnlock</Normal Text><Symbol>(</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>byte</Data Type><Normal Text> singleByte</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes</Data Type><Normal Text> bytesUnspecifiedLength</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes1</Data Type><Normal Text> bytes1Length</Normal Text><Symbol>,</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes99</Data Type><Normal Text> bytes99Length</Normal Text><br/>
<Normal Text>	</Normal Text><Symbol>)</Symbol><Normal Text> </Normal Text><Symbol>{</Symbol><br/>
<Normal Text>		</Normal Text><Comment>// General.</Comment><br/>
<Normal Text>		</Normal Text><Built-in>require</Built-in><Symbol>(</Symbol><Normal Text>singleByte </Normal Text><Symbol>==</Symbol><Normal Text> bytes1Length</Normal Text><Symbol>);</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Arithmetic.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> resultAbs </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>abs</Built-in><Symbol>(</Symbol><Normal Text>intExample</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> resultMin </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>min</Built-in><Symbol>(</Symbol><Normal Text>intExample</Normal Text><Symbol>,</Symbol><Normal Text> </Normal Text><Decimal>100</Decimal><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> resultMax </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>max</Built-in><Symbol>(</Symbol><Normal Text>intExample</Normal Text><Symbol>,</Symbol><Normal Text> </Normal Text><Decimal>100</Decimal><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> resultWithin </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>within</Built-in><Symbol>(</Symbol><Normal Text>intExample</Normal Text><Symbol>,</Symbol><Normal Text> </Normal Text><Decimal>0</Decimal><Symbol>,</Symbol><Normal Text> </Normal Text><Decimal>100</Decimal><Symbol>);</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Hashing.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultHash160 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>hash160</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultHash256 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>hash256</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultRipeMd160 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>ripemd160</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultSha1 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>sha1</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultSha256 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>sha256</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Signature checking.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultChecksig </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>checkSig</Built-in><Symbol>(</Symbol><Normal Text>sigExample</Normal Text><Symbol>,</Symbol><Normal Text> pubkeyExample</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultCheckMultiSig </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>checkMultiSig</Built-in><Symbol>([</Symbol><Normal Text>sigExample</Normal Text><Symbol>],</Symbol><Normal Text> </Normal Text><Symbol>[</Symbol><Normal Text>pubkeyExample</Normal Text><Symbol>]);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> resultCheckDataSig </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Built-in>checkDataSig</Built-in><Symbol>(</Symbol><Normal Text>datasigExample</Normal Text><Symbol>,</Symbol><Normal Text> bytesUnspecifiedLength</Normal Text><Symbol>,</Symbol><Normal Text> pubkeyExample</Normal Text><Symbol>);</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Locking Bytecode.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>bytes</Data Type><Normal Text> p2pkh </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Keyword>new</Keyword><Normal Text> </Normal Text><Built-in>LockingBytecodeP2PKH</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes</Data Type><Normal Text> p2sh20 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Keyword>new</Keyword><Normal Text> </Normal Text><Built-in>LockingBytecodeP2SH20</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes</Data Type><Normal Text> p2sh32 </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Keyword>new</Keyword><Normal Text> </Normal Text><Built-in>LockingBytecodeP2SH32</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes</Data Type><Normal Text> nullData </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Keyword>new</Keyword><Normal Text> </Normal Text><Built-in>LockingBytecodeNullData</Built-in><Symbol>(</Symbol><Normal Text>bytesUnspecifiedLength</Normal Text><Symbol>);</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Keywods.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> exampleTrue </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Keyword>true</Keyword><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bool</Data Type><Normal Text> exampleFalse </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Keyword>false</Keyword><Symbol>;</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Control structures.</Comment><br/>
<Normal Text>		</Normal Text><Control Structures>if</Control Structures><Normal Text> </Normal Text><Symbol>(</Symbol><Normal Text>exampleTrue</Normal Text><Symbol>)</Symbol><Normal Text> </Normal Text><Symbol>{</Symbol><br/>
<Normal Text>			</Normal Text><Built-in>require</Built-in><Symbol>(</Symbol><Normal Text>singleByte </Normal Text><Symbol>==</Symbol><Normal Text> bytes1Length</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Symbol>}</Symbol><Normal Text> </Normal Text><Control Structures>else</Control Structures><Normal Text> </Normal Text><Control Structures>if</Control Structures><Normal Text> </Normal Text><Symbol>(</Symbol><Normal Text>exampleFalse</Normal Text><Symbol>)</Symbol><Normal Text> </Normal Text><Symbol>{</Symbol><br/>
<Normal Text>			</Normal Text><Built-in>require</Built-in><Symbol>(</Symbol><Normal Text>singleByte </Normal Text><Symbol>==</Symbol><Normal Text> bytes1Length</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Symbol>}</Symbol><Normal Text> </Normal Text><Control Structures>else</Control Structures><Normal Text> </Normal Text><Symbol>{</Symbol><br/>
<Normal Text>			</Normal Text><Built-in>require</Built-in><Symbol>(</Symbol><Normal Text>singleByte </Normal Text><Symbol>==</Symbol><Normal Text> bytes1Length</Normal Text><Symbol>);</Symbol><br/>
<Normal Text>		</Normal Text><Symbol>}</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Units.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleSatoshis </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>satoshis</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleSats </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>sats</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleFinney </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>finney</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleBits </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>bits</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleBitcoin </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>bitcoin</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleSeconds </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>seconds</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleMinutes </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>minutes</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleHours </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>hours</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleDays </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>days</Unit><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>int</Data Type><Normal Text> exampleWeeks </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Decimal>1</Decimal><Normal Text> </Normal Text><Unit>weeks</Unit><Symbol>;</Symbol><br/>
<Normal Text></Normal Text><br/>
<Normal Text>		</Normal Text><Comment>// Misc.</Comment><br/>
<Normal Text>		</Normal Text><Data Type>string</Data Type><Normal Text> exampleString </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><String>"This is an example string"</String><Symbol>;</Symbol><br/>
<Normal Text>		</Normal Text><Data Type>bytes</Data Type><Normal Text> exampleHex </Normal Text><Symbol>=</Symbol><Normal Text> </Normal Text><Hex>0xaabbccddeeff</Hex><Symbol>;</Symbol><br/>
<Normal Text>	</Normal Text><Symbol>}</Symbol><br/>
<Symbol>}</Symbol><br/>
