#include <iostream>
#include <map>
int main() {
// your code goes here
std::string name;
std::string second_name;
int mark_1;
int mark_2;
int mark_3;
std::map<std::string, int> m;
std::cin >> name >> second_name >> mark_1 >> mark_2 >> mark_3;
m[name + ' ' + second_name] = mark_1 + mark_2 + mark_3;
std::cout << m["vasyan pupkin"];
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8bWFwPgoKaW50IG1haW4oKSB7CgkvLyB5b3VyIGNvZGUgZ29lcyBoZXJlCgkKCXN0ZDo6c3RyaW5nIG5hbWU7CglzdGQ6OnN0cmluZyBzZWNvbmRfbmFtZTsKCWludCBtYXJrXzE7CglpbnQgbWFya18yOwoJaW50IG1hcmtfMzsKCQoJc3RkOjptYXA8c3RkOjpzdHJpbmcsIGludD4gbTsKCQoJc3RkOjpjaW4gPj4gbmFtZSA+PiBzZWNvbmRfbmFtZSA+PiBtYXJrXzEgPj4gbWFya18yID4+IG1hcmtfMzsKCQoJbVtuYW1lICsgJyAnICsgc2Vjb25kX25hbWVdID0gbWFya18xICsgbWFya18yICsgbWFya18zOwoJCglzdGQ6OmNvdXQgPDwgbVsidmFzeWFuIHB1cGtpbiJdOwoJCglyZXR1cm4gMDsKfQ==