#include <cmath>
#include <iostream>
using namespace std;
class Val {
int a;
float b;
public:
Val& operator= (const int _a) {a = _a; b = _a + fmod(b, 1.0F); return *this;}
Val& operator= (const float _b) {b = _b; a = trunc(_b); return *this;}
operator int() {return a;}
operator float() {return b;}
};
int main() {
Val foo;
foo = 1.3F;
cout << static_cast<int>(foo) << endl << static_cast<float>(foo) << endl;
foo = 13;
cout << static_cast<int>(foo) << endl << static_cast<float>(foo) << endl;
}
I2luY2x1ZGUgPGNtYXRoPgojaW5jbHVkZSA8aW9zdHJlYW0+CnVzaW5nIG5hbWVzcGFjZSBzdGQ7CgpjbGFzcyBWYWwgewoJaW50IGE7CglmbG9hdCBiOwpwdWJsaWM6CglWYWwmIG9wZXJhdG9yPSAoY29uc3QgaW50IF9hKSB7YSA9IF9hOyBiID0gX2EgKyBmbW9kKGIsIDEuMEYpOyByZXR1cm4gKnRoaXM7fQoJVmFsJiBvcGVyYXRvcj0gKGNvbnN0IGZsb2F0IF9iKSB7YiA9IF9iOyBhID0gdHJ1bmMoX2IpOyByZXR1cm4gKnRoaXM7fQoJb3BlcmF0b3IgaW50KCkge3JldHVybiBhO30KCW9wZXJhdG9yIGZsb2F0KCkge3JldHVybiBiO30KfTsKCmludCBtYWluKCkgewoJVmFsIGZvbzsKCQoJZm9vID0gMS4zRjsKCQoJY291dCA8PCBzdGF0aWNfY2FzdDxpbnQ+KGZvbykgPDwgZW5kbCA8PCBzdGF0aWNfY2FzdDxmbG9hdD4oZm9vKSA8PCBlbmRsOwoJCglmb28gPSAxMzsKCQoJY291dCA8PCBzdGF0aWNfY2FzdDxpbnQ+KGZvbykgPDwgZW5kbCA8PCBzdGF0aWNfY2FzdDxmbG9hdD4oZm9vKSA8PCBlbmRsOwp9