Advertisement
Guest User

Untitled

a guest
Dec 18th, 2014
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.32 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. void main() {
  5.     float res = 0, x = 2, a = 1.5, b = 1;
  6.     __asm{
  7.         finit // инициализация сопроцессора
  8.  
  9.         // sin(1.5*x)
  10.         fld x
  11.         fld a
  12.         fmul
  13.         fsin
  14.  
  15.         // 1/x
  16.         fld b
  17.         fld x
  18.         fdiv
  19.  
  20.         // сложить
  21.         fadd
  22.  
  23.         fstp res
  24.     }
  25.     cout << res;
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement