qBasik:
INPUT A
INPUT B
IF A>0 AND B>0
THEN
S=A+B
PRINT S
PRINT " "
S=A*B
PRINT S
ELSE
S=A-B
PRINT S
PRINT " "
S=A/B
PRINT S
END
C/C++ :
#include
#include
using namespace std;
int main()
{
int a,b;
cin>>a;
cin>>b;
if(a>0 && b>0)
{
cout<<a+b<<" "<<a*b<<endl;</p>
}
else
{
float c=a/b;
cout<<a-b<<" "<<c<<endl;</p>
}
system("PAUSE");
return 0;
}