C++ String c_str()This function returns a pointer to an array that contains null terminated sequence of characters. SyntaxConsider a string str. Syntax would be: ParameterIt does not contain any parameter. Return valueIt returns a pointer to the c-string representation of the string object's value. ExampleLet's see the simple example. Output: String value is: Computer is my favorite subject
Next TopicC++ Strings
|
JavaTpoint offers too many high quality services. Mail us on h[email protected], to get more information about given services.
JavaTpoint offers college campus training on Core Java, Advance Java, .Net, Android, Hadoop, PHP, Web Technology and Python. Please mail your requirement at [email protected].
Duration: 1 week to 2 week