SilverScreen Solid Modeler

strcmp

strcmp

Previous topic Next topic  

strcmp

Previous topic Next topic JavaScript is required for the print function  

StandardCLibrary

 

int strcmp( char *s1, char *s2 )

 

char *s1;         /* a string */

char *s2;         /* a string */

 

 




Synopsis

#include "string.h"

 

The strcmp function compares strings s1 and s2 .

 

 

Parameters

s1 and s2 are null-terminated strings.

 

 

Return Value

strcmp returns 0 if the two strings are identical. If s1 is lexicographically less than s2, then a negative value is returned; otherwise, a positive value is returned.

 

 

See Also

strncmp