Let's say I have the following function in C:
void sum(){
float a,b,ans;
a = 1.0; b = 2.0; //I do use scanf for a and b for for simplicity i'll just use random numbers
ans = a+b;
printf("Answer is %.2f",ans);
}
How can I make the exact same behavior (mathematically operate 2 variables and store the result in another variable) using inline assembly in C? Replacing only the ans = a+b line would be ideal, I'm using gcc or MinGW for windows version of Codeblock compilers if it changes anything.