Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- double x, a = 2.0;
- cin >> x;
- _asm {
- fld x
- fld a
- fyl2x
- fld st
- frndint
- fsub st(1), st
- fxch st(1)
- f2xm1
- fld1
- fadd
- fscale
- fstp a
- }
- cout << a << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment