Untitled

mail@pastecode.io avatar
unknown
plain_text
2 years ago
510 B
0
Indexable
Never
#include <iostream>
#include <string>
#include <vector>
using namespace std;
vector<char> func(string &a , vector<char> &b) {
	int i;
	for (i = 0; i < a.size(); i++)
	{
		b.push_back(a[i]);
	}
	for ( i = 0; i < a.size(); i++)
	{
		if ((b[i] >= 65 ) && (b[i] <= 90)) b[i] += 32;
		else if ((b[i] >= 97) && (b[i] <= 122)) b[i] -= 32;
	}
	return b;
};
int main()
{
	vector<char> b;
	string a;
	getline(cin,a);
	func(a, b);
	for (int i = 0; i < b.size(); i++)
	{
		cout << b[i];
	}
}