Задание 10:
#include <iostream>
using namespace std;
int main()
{
for(int i=1; i <= 32; i*=2)
cout << i << " ";
cin.get();
}
Задание 11:
#include <string.h>
char str;
int counter=0;
do
cout << "Enter symbol -> ";
cin >> str;
if(str>64&&str<91)
str+=32;
cout << str << endl;
counter++;
else if(str>96&&str<123)
str-=32;
}while(str!='.');
cout << "Opearations counter - " << counter << endl;
Задание 10:
#include <iostream>
using namespace std;
int main()
{
for(int i=1; i <= 32; i*=2)
cout << i << " ";
cin.get();
}
Задание 11:
#include <iostream>
#include <string.h>
using namespace std;
int main()
{
char str;
int counter=0;
do
{
cout << "Enter symbol -> ";
cin >> str;
if(str>64&&str<91)
{
str+=32;
cout << str << endl;
counter++;
}
else if(str>96&&str<123)
{
str-=32;
cout << str << endl;
counter++;
}
}while(str!='.');
cout << "Opearations counter - " << counter << endl;
cin.get();
cin.get();
}