#12528: C++AC解


st990185@gmail.com (風神)


#include<iostream>
using namespace std;

int main()
{
int a,b;
while(cin>>a>>b)
{
if((a==7 && b==30)||(a>7 && a<17))
cout<<"At School"<<endl;
else
cout<<"Off School"<<endl;

}
return 0;
}

 

 

#16752: Re:C++AC解


jonjonjon (白夜)


#include
using namespace std;

int main()
{
int a,b;
while(cin>>a>>b)
{
if((a==7 && b==30)||(a>7 && a<17))
cout<<"At School"<<endl;
else
cout<<"Off School"<<endl;

}
return 0;
}

 

 

 

#include<iostream>

using namespace std;

 

int main()

{

int h,m;

cin>>h>>m;

cout<<((h<7)?"Off School":(h>=17)?"Off School":(h==7&&m<30)?"Off School":"At School");

return 0;

}