removes occurence of str2, str3 ... in order to provide better documentation
[scilab.git] / scilab / modules / string / help / en_US / strcmp.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE MAN SYSTEM "../../../../modules/helptools/help.dtd">
3 <MAN>
4   <LANGUAGE>eng</LANGUAGE>
5
6   <TITLE>strcmp</TITLE>
7
8   <TYPE>Scilab Function</TYPE>
9
10   <DATE>$LastChangedDate: 2006-08-08 16:57:13 +0200 (Tue, 08 Aug 2006)
11   $</DATE>
12
13   <SHORT_DESCRIPTION name="strcmp">compare character
14   strings</SHORT_DESCRIPTION>
15
16   <CALLING_SEQUENCE>
17     <CALLING_SEQUENCE_ITEM>res =
18     strcmp(string_one,string_two,[,'i'])</CALLING_SEQUENCE_ITEM>
19   </CALLING_SEQUENCE>
20
21   <PARAM>
22     <PARAM_INDENT>
23       <PARAM_ITEM>
24         <PARAM_NAME>string_one</PARAM_NAME>
25
26         <PARAM_DESCRIPTION>
27           <SP>: string or matrix of strings</SP>
28         </PARAM_DESCRIPTION>
29       </PARAM_ITEM>
30
31       <PARAM_ITEM>
32         <PARAM_NAME>string_two</PARAM_NAME>
33
34         <PARAM_DESCRIPTION>
35           <SP>: string or matrix of strings</SP>
36         </PARAM_DESCRIPTION>
37       </PARAM_ITEM>
38
39       <PARAM_ITEM>
40         <PARAM_NAME>'i'</PARAM_NAME>
41
42         <PARAM_DESCRIPTION>
43           <SP>: parameter to do stricmp, default value is 's'</SP>
44         </PARAM_DESCRIPTION>
45       </PARAM_ITEM>
46
47       <PARAM_ITEM>
48         <PARAM_NAME>res</PARAM_NAME>
49
50         <PARAM_DESCRIPTION>
51           <SP>: matrix.</SP>
52         </PARAM_DESCRIPTION>
53       </PARAM_ITEM>
54     </PARAM_INDENT>
55   </PARAM>
56
57   <DESCRIPTION>
58     <P><VERB>res = strcmp(string_one,string_two)</VERB> returns an integral
59     value indicating the relationship between the strings.</P>
60
61     <P>A value greater than zero indicates that the first character that does
62     not match has a greater value in <VERB>string_one</VERB> than in
63     <VERB>string_two</VERB></P>
64
65     <P>And a value less than zero indicates the opposite.</P>
66   </DESCRIPTION>
67
68   <EXAMPLE><![CDATA[
69
70 TXT1 = ['scilab','SciLab';'Strcmp','STRcmp'];
71 TXT2 = ['ScIlAb','sciLab';'sTrCmP','StrCMP'];
72 strcmp(TXT1,TXT2)
73 strcmp(TXT1,'scilab')
74 strcmp(TXT1,'SciLab')
75 strcmp(TXT1,TXT2,'i')
76  
77   ]]></EXAMPLE>
78
79   <SEE_ALSO>
80     <SEE_ALSO_ITEM>
81       <LINK>strcat</LINK>
82     </SEE_ALSO_ITEM>
83
84     <SEE_ALSO_ITEM>
85       <LINK>strcmpi</LINK>
86     </SEE_ALSO_ITEM>
87   </SEE_ALSO>
88 </MAN>