C++字符串逆排序

时间:2014-02-17 05:19:57   收藏:0   阅读:432
#include <cstdlib>
#include <string>
#include <iostream>
#include <thread>
#include <array>

using namespace std;
	
int main(int argc, char *argv[])
{
	string str;
	cin>>str;
	string rstr;
	rstr.replace(rstr.begin(), rstr.end(),str.rbegin(),str.rend());
	cout<<rstr;
	while(1);
    return EXIT_SUCCESS;
}

原文:http://blog.csdn.net/drivermonkey/article/details/19289953

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!