MB-820 · Question #31
You have a decimal variable named AmountLCY. You need to round up the variable to four decimal places. Which result value should you use? A. B. C. D.
The correct answer is D. Result := Round(AmountLCY, 0.0001, '>'). Use '>' to round up. 1234.56789 0.001(Precision) >(Direction) --> 1234.568 Note: System.Round(Decimal [, Decimal] [, Text]) Method Rounds the value of a numeric variable. NewNumber := System.Round(Number: Decimal [, Precision: Decimal] [, Direction: Text]) This method can be…
Question
You have a decimal variable named AmountLCY. You need to round up the variable to four decimal places. Which result value should you use? A. B. C. D.
Options
- AResult := Round(AmountLCY, 4, '<')
- BResult := Round(AmountLCY, 0.0001, '>')
- CResult := Round(AmountLCY, 0.0001, '<')
- DResult := Round(AmountLCY, 0.0001, '>')
How the community answered
(33 responses)- A6% (2)
- B9% (3)
- C3% (1)
- D82% (27)
Explanation
Use '>' to round up. 1234.56789 0.001(Precision) >(Direction) --> 1234.568 Note: System.Round(Decimal [, Decimal] [, Text]) Method Rounds the value of a numeric variable. NewNumber := System.Round(Number: Decimal [, Precision: Decimal] [, Direction: Text]) This method can be invoked without specifying the data type name. - [Optional] Direction This optional parameter specifies how to round the Number parameter. The default rounding method is '='. The following are the options for rounding: '=' rounds up or down to the nearest value (default). Values of 5 or greater are rounded up. Values less than 5 are rounded down. https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/methods- auto/system/system-round-method
Topics
Community Discussion
No community discussion yet for this question.