Comment on Tutorial - Reverse a String in C++ By Grant Braught



Comment Added by : gavin

Comment Added at : 2013-02-21 12:30:57

Comment on Tutorial : Reverse a String in C++ By Grant Braught
You are using stl; why do it by hand? All you need is a one liner that uses a built in algorithm...

reverse(MyWord.begin(), MyWord.end());

that works as we can treats a string as a array of characters.


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Very nice
View Tutorial          By: sharath at 2012-07-17 11:31:20

2. nice information, thanks dost.
View Tutorial          By: Bhargavi Menpara at 2013-02-12 08:11:23

3. hi.I am new in j2me and really want to learn more
View Tutorial          By: snehal at 2011-12-01 11:46:22

4. Hi,first of all thats for this code developer, its
View Tutorial          By: Kathir at 2008-02-08 06:16:51

5. Hello, this is a very good post. I'm a newbee in J
View Tutorial          By: Brian at 2013-04-11 09:07:33

6. thanks geek, it really helped me. cheers
View Tutorial          By: Geoffrey at 2015-06-08 09:00:40

7. why java from two to the power 7 bit was upgraded
View Tutorial          By: avinash at 2013-05-28 08:34:24

8. how this program is work , please, tell
View Tutorial          By: rohit kumar at 2015-10-30 12:22:05

9. Thank you very much for your help!!
View Tutorial          By: Ajay Singh at 2009-10-21 22:17:21

10. super explination.
View Tutorial          By: nagarjun reddy at 2013-01-19 13:55:16