Questions tagged as 'float'

1
answer

exercise Floating-point error

I have a list of floating point errors and I'm having some difficulty with one of the issues. If anyone can help me, I'm grateful. For the code below, I need to justify the reason for the error. int main () { double x; x = 0.; printf(...
asked by 31.03.2017 / 05:08
4
answers

Mathematical division needs

On the Windows calculator: 9 / 3,0001 = 2,999 ... In my program: 9 / 3,0001 = 3; I would like to get this level of precision using C. See excerpts from my program: double op(double num1, double num2, char c) { if(c == '/')...
asked by 25.10.2014 / 18:23
1
answer

Ajax - Float Parameter

Hello, I need ajax help, I think it's a silly thing, but I'm having a hard time and I did not find anything related on the internet about it, I need to pass ajax parameter to my controller, but float type, I created a json object to try to get t...
asked by 28.12.2015 / 12:46
3
answers

Source code does not compile [closed]

#include <iostream> /* run this program using the console pauser or add your own getch, system("pause") or input loop */ int main() { float parede, litros; printf ("Calcular litros de tintas por metros quadrados.\n"); print...
asked by 22.11.2017 / 06:52
1
answer

invalid operands to binary% (have 'float' and 'int') [closed]

When compiling the code I get the error in the title of the question for the line res100=notas%100; How to solve? Code: float notas,N100,M1,M050,M025,M010,M005,M001,res100,res2,res1,res05,res025,res010,res005,res001,N50,N20,...
asked by 15.10.2018 / 23:55
1
answer

Formatting float number in list

I have a dataframe with columns of Latitude and Longitude, in the format string Atibaia['LATITUDE'].head() 140 -231,124,852,387,647 245 -231,159,749,902,692 254 -23,116,747,205 512 -231,560,912,572,211 1348 -23,11...
asked by 30.03.2018 / 04:06