C++ Math Library Reference | ![]() ![]() |
Compare the first n
characters of two strings
C++ Prototype
mwArray strncmp(const mwArray &str1, const mwArray &str2=mwArray::DIN, const mwArray &n=mwArray::DIN);
C++ Syntax
#include "matlab.hpp" mwArray S, T, n; // Input argument(s) mwArray k, TF; // Return value k = strncmp("str1"
,"str2"
,n); TF = strncmp(S,T,n);
MATLAB Syntax
k = strncmp('str1
','str2
',n) TF = strncmp(S,T,n)
See Also
strncmp
Calling Conventions![]() | strmatch | strncmpi | ![]() |