
02.03.2010, 22:25
|
|
Участник форума
Регистрация: 18.09.2009
Сообщений: 176
Провел на форуме: 462678
Репутация:
102
|
|
Сообщение от Idainet
If(1)
Код:
# include <iostream>
int main() {
int a,b;
std::cin >> a >> b;
std:: cout << ((a+b)%2 ? "Different ":"Same ") << "parity\n";
return 0;
}
If(2)
Код:
# include <iostream>
int main() {
double a,b,c;
std :: cin >> a >> b >> c;
(a > b ^ b > c ) ? (a*=-1, b*=-1,c*=-1):(a*=2,b*=2,c*=2);
std :: cout << a << b << c;
return 0;
}
можна в скомпилированном варианте?
|
|
|