#include <iostream>
using namespace std;
int suma_dzielnikow(int n) {
int suma = 0;
for (int i = 1; i <= n; i++)
if (n % i == 0) suma += i;
return suma;
}
int main() {
cout << suma_dzielnikow(7) << " " << suma_dzielnikow(16) << endl;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKaW50IHN1bWFfZHppZWxuaWtvdyhpbnQgbikgewogICAgaW50IHN1bWEgPSAwOwogICAgZm9yIChpbnQgaSA9IDE7IGkgPD0gbjsgaSsrKQogICAgaWYgKG4gJSBpID09IDApIHN1bWEgKz0gaTsKICAgIHJldHVybiBzdW1hOwp9CgppbnQgbWFpbigpIHsKICAgIGNvdXQgPDwgc3VtYV9kemllbG5pa293KDcpIDw8ICIgIiA8PCBzdW1hX2R6aWVsbmlrb3coMTYpIDw8IGVuZGw7CiAgICByZXR1cm4gMDsKfQoKCgo=