Logo

Programming-Idioms

History of Idiom 81 > diff from v23 to v24

Edit summary for version 24 by :
New C implementation by user [D̵̢̛̺̦̝̻̮̟̤̥̘̬̰̮͐̆͋ͯͪ̅ͦͧ̒̅̔ͧ̏͌̓ͯ̅̾ͯ͢O̴̡̱̺͉̪͙̘̰̝̹͗͌ͦͣͮ̐̃ͮͧͣ̚͟͢͠O̸̢̨̩̼͇̯ͨ̾̆ͭ̾̇̎͌͂̍ͫ͌͑̈́͛̈̌ͣM̰̣̖̭̯̥̰̦̣̬ͧͥ́ͣ͛͢͡ ̘͎̞̞͓̗̺̯̭̲͔͕͎̐̐ͧ̍́͞Ȋ̢̲̟̦͚̦͇̞̝͕̈ͧ̇͌͛ͮͭ̽̒̿̂ͮ̌̅͡͡S̵̶̢̻̘̜̲̭̦̖̬̺ͯͪ̑̑͜ͅ ̵̴͕̠͓͎̦̞̜̙̱̦̥̠̰̈ͮͣͪ̊́̚ͅU̦͚̯̗ͪ̔ͯ̍͌́͒́̃̅͊̂́͒́͘P̨̰̬͙̬̑͌ͨͤ̀͊ͦ̔̀̀O̡̨̼͔̙͖̙̻͕̣͍̜͂͌͆̽͂̽͋̊̚͢ͅN̛̝̲̤̺̣̻̜̎̽ͨ͋̿̽ͫ̚ ̜̹̖͖̞̺͈̘͈͈̣͚́ͮ͌̌̇̉ͮͦͤ̆ͣ͒ͨ̓ͪ͋͡͞U͈̣̯͇̘̦̗̥̱͐̐́́͗̇͊͝͡S̴̛͙̹̱͚̲̭̩͉̩̤̫̜͇͉͍̏ͣ͛̐ͥͬͣ̔̌̃́]

Version 23

2016-02-18, 18:19:05

Version 24

2016-02-18, 18:19:05

Idiom #81 Round floating point number to integer

Declare integer y and initialize it with the rounded value of floating point number x .
Ties (when the fractional part of x is exactly .5) must be rounded up (to positive infinity).

Idiom #81 Round floating point number to integer

Declare integer y and initialize it with the rounded value of floating point number x .
Ties (when the fractional part of x is exactly .5) must be rounded up (to positive infinity).