Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

New answers tagged


Your problem is that you are doing integer maths. mr = (130-20)/(1023-205) reduces to: mr = 110/818 Which normally equates to: mr = 0.135 But since all those numbers are integers the result is an integer, and is truncated at the decimal point, which means that mr is assigned: mr = 0 You can force floating point maths by either including a decimal ...

Top 50 recent answers are included