#include <iostream>
#include <map>
#include <string>
#include <sstream>
using namespace std;
class ICommand{
public:
    virtual void execute(istream &args) = 0;  
};

class Add : public ICommand{
    void execute(istream &args){
        int a,b;
        args >> a;
        args >> b;
        cout << "Add result:" <<  a + b << endl;
    }
};

class Negate : public ICommand{
    void execute(istream &args){
        int a;
        args >> a;
        cout <<"Negate result:"<< -a << endl;
    }
};

int main(){
    map<string,ICommand*> commands;
    
    commands["Add"] = new Add();
    commands["Negate"] = new Negate();
    string cmd;
    while(cin >> cmd){
        auto it = commands.find(cmd);
        if(it!= commands.end()){
            it->second->execute(cin);
        }else{
            cout << "Unknown command \"" << cmd << "\"." << endl;
        }
    }
}