home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2003 December
/
Chip_2003-12_cd2.bin
/
oo
/
download
/
f_0019
/
sbasic.jar
/
text
/
sbasic
/
common
/
03080701.xml
< prev
next >
Wrap
Extensible Markup Language
|
2003-01-16
|
3KB
|
55 lines
<?xml version="1.0" encoding="utf-8"?>
<html><head><title>Funkce Sgn [Runtime]</title><meta name="filename" content="text/sbasic/common/03080701"/><meta name="language" content="en-US"/><help:css-file-link xmlns:help="http://openoffice.org/2000/help"/><!--The CSS style header method for setting styles--><style type="text/css">
table.Tabelle1{
}
span.Tabelle1A{
width:8.999cm;}
td.Tabelle1A3{
}
p.P1{
}
p.P2{
}
span.T1{
font-weight:bold;}
</style></head><body>
<help:to-be-embedded Eid="sgn" xmlns:help="http://openoffice.org/2000/help">
<p class="Head1"><help:link Id="66485">Funkce Sgn [Runtime]</help:link></p>
<p class="Paragraph">Vrátí celé číslo v rozsahu -1 až 1, které označuje, zda je číslo zadané do funkce kladné, záporné nebo nula.</p>
</help:to-be-embedded>
<p class="Paragraph"><span class="T1">Syntaxe</span>:</p>
<p class="Paragraph">Sgn (Číslo) <help:key-word value="Sgn" tag="kw66485_1" xmlns:help="http://openoffice.org/2000/help"/></p>
<p class="Paragraph"><span class="T1">Vrácená hodnota</span>:</p>
<p class="Paragraph">Typu Integer</p>
<p class="Paragraph"><span class="T1">Parametr</span>:</p>
<p class="Paragraph">Číslo: Číselný výraz, na základě kterého bude určena návratová hodnota funkce.</p>
<table><tr class=""><th style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">Číslo</p>
</span></th><th style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">Vrácená hodnota</p>
</span></th></tr><tr class=""><td style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">záporné</p>
</span></td><td style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">Funkce Sgn vrátí hodnotu -1.</p>
</span></td></tr><tr class=""><td class="Tabelle1A3" style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">0</p>
</span></td><td style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">Funkce Sgn vrátí hodnotu 0.</p>
</span></td></tr><tr class=""><td style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">kladné</p>
</span></td><td style="text-align:left;"><span class="Tabelle1A">
<p class="TextInTable">Funkce Sgn vrátí hodnotu 1.</p>
</span></td></tr></table>
<p class="Paragraph"/>
<p class="P2">Příklad:</p>
<p class="PropText">Sub ExampleSgn</p>
<p class="PropText">Print sgn(-10) REM returns -1</p>
<p class="PropText">Print sgn(0) <text:s text:c="2" xmlns:text="http://openoffice.org/2000/text"/>REM returns 0</p>
<p class="PropText">Print sgn(10) <text:s text:c="" xmlns:text="http://openoffice.org/2000/text"/>REM returns 1</p>
<p class="PropText">end sub</p>
<p class="PropText"/>
</body></html>