How do I get the length of a string in Octave?
I looked here and here and here for some equivalent to PHP's strlen(), but I did not find anything.
As the first link you posted explains, strings are just matrices, so you can use the regular matrix operations, for instance length.
> x = "teststring";
> length(x)
ans = 10
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With