Time:03-19
CodePudding user response:
Sum=% d ; Instead of Sum=% . ;
because int type and type double data in memory is not the same, % d output said to let the computer by using the format to get data of type int, and half of the int or double memory, so the picked are 0. (low 4 bytes, 32 bit system)
Page link:https//www.codepudding.com/Backend/104880.html