+ 2
How to find the length of a string in c++?
9 Answers
+ 4
str.length()
+ 3
in c++ to find the length of string make use of strlen(var_name); var_name is the name of the variable whose length is to be found
+ 2
weather str is a keyword
+ 2
str is whatever your string is called.
it's a function m strings have, it will return their length
+ 2
stringname.length();
+ 2
thx
+ 2
how to declare a string whose size is not yet known
+ 2
I have declared char str[] but it is giving me error why so
+ 1
That's a problem in C++, C# has this covered by making strings a seperate data type, you can use dynamic memory