 Atopo

2611    Curtain_67 asbefore...     y_yy    BT7274 こんにちは   Titanium_0  Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std;

int main()
{
int a, b, c;
cin >> a >> b >> c;

int x = a, y = b, z = c;

if (b < a)
{
int t = a;
a = b;
b = t;
}
if (c < a)
{
int t = a;
a = c;
c = t;
}
if (c < b)
{
int t = b;
b = c;
c = t;
}

cout << a << endl << b << endl << c << endl << endl;
cout << x << endl << y << endl << z << endl;

return 0;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

int main()
{
double x;
scanf("%lf", &x);

double sum = 0;
if (x > 2000)
{
double y = 3000;
if (x < 3000) y = x;
sum += (y - 2000) * 0.08;
}
if (x > 3000)
{
double y = 4500;
if (x < 4500) y = x;
sum += (y - 3000) * 0.18;
}
if (x > 4500) sum += (x - 4500) * 0.28;

if (sum == 0) printf("Isento");
else printf("R\$ %.2lf\n", sum);

return 0;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

int a , b , c , d ;

int main()
{
scanf("%d%d%d%d", &a, &b, &c, &d);

int start = a * 60 + b;
int end = c * 60 + d;

int spent_time = end - start;
if (spent_time <= 0) spent_time += 1440;

printf("O JOGO DUROU %d HORA(S) E %d MINUTO(S)", spent_time / 60, spent_time % 60);

return 0;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<vector>
#include<algorithm>

using namespace std ;

double a , b , c ;
vector<double>nums ;

int main ()
{
for (int i = 0 ; i < 3 ; i++){
int num ;
cin >> num ;
nums.push_back(num) ;
}

sort (nums.begin() , nums.end()) ;

a = nums ;
b = nums ;
c = nums ;

cout << a << "  " << b << "  " << c << endl ;

if (a >= b + c){
cout << "NAO FORMA TRIANGULO\n" ;
}else{
if (a * a == b * b + c * c){
cout << "TRIANGULO RETANGULO\n" ;
}else if (a * a < b * b + c * c){
cout << "TRIANGULO ACUTANGULO\n" ;
}else {
cout << "TRIANGULO OBTUSANGULO\n";
}
if (a == b && b == c){
cout << "TRIANGULO EQUILATERO\n" ;
}else if (b == c && a != b){
cout << "TRIANGULO ISOSCELES\n" ;
}else if (a == b &&  a != c){
cout << "TRIANGULO ISOSCELES\n" ;
}
}

return 0 ;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std;

int main()
{
string a, b, c;
cin >> a >> b >> c;

{
if (b == "ave")
{
if (c == "carnivoro") cout << "aguia" << endl;
else cout << "pomba" << endl;
}
else
{
if (c == "onivoro") cout << "homem" << endl;
else cout << "vaca" << endl;
}
}
else
{
if (b == "inseto")
{
if (c == "hematofago") cout << "pulga" << endl;
else cout << "lagarta" << endl;
}
else
{
if (c == "hematofago") cout << "sanguessuga" << endl;
else cout << "minhoca" << endl;
}
}

return 0;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

int main()
{
double salary;
scanf("%lf", &salary);

double x;

if (salary <= 400) x = 0.15;
else if (salary <= 800) x = 0.12;
else if (salary <= 1200) x = 0.1;
else if (salary <= 2000) x = 0.07;
else x = 0.04;

printf("Novo salario: %.2lf\n", salary * (1 + x));
printf("Reajuste ganho: %.2lf\n", salary * x);
printf("Em percentual: %.0lf %%", x * 100);

return 0;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

int a, b ;

int main ()
{
cin >> a >> b ;

if ( b > a){
printf ("O JOGO DUROU %d HORA(S)" , b - a) ;
}else if (b == a){
printf ("O JOGO DUROU %d HORA(S)" , 24) ;
}else {
printf ("O JOGO DUROU %d HORA(S)" , 24 - a + b) ;
}

return 0 ;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

int a, b ;

int main ()
{
cin >> a >> b ;

if ( b > a){
printf ("O JOGO DUROU %d HORA(S)" , b - a) ;
}else if (b == a){
printf ("O JOGO DUROU %d HORA(S)" , 24) ;
}else {
printf ("O JOGO DUROU %d HORA(S)" , 24 - a + b) ;
}

return 0 ;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

double a ;

int main ()
{
cin >> a ;

if (a >=0 && a <= 25){
cout << "Intervalo [0,25]" << endl ;
}else if (a > 25 && a <= 50){
cout << "Intervalo (25,50]" << endl ;
}else if (a > 50 && a <= 75){
cout << "Intervalo (50,75]" << endl ;
}else if (a > 75 && a <= 100){
cout << "Intervalo (75,100]" << endl ;
}else {
cout << "Fora de intervalo" << endl;
}

return 0 ;
}


Atopo
5天前
#include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>

using namespace std ;

double a ;

int main ()
{
cin >> a ;

if (a >=0 && a <= 25){
cout << "Intervalo [0,25]" << endl ;
}else if (a > 25 && a <= 50){
cout << "Intervalo (25,50]" << endl ;
}else if (a > 50 && a <= 75){
cout << "Intervalo (50,75]" << endl ;
}else if (a > 75 && a <= 100){
cout << "Intervalo (75,100]" << endl ;
}else {
cout << "Fora de intervalo" << endl;
}

return 0 ;
}