- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
29-08-19 09:01 PM
This is related to the Zeller's Congruence algorithm where there is a requirement to use Modulo to get the actual day of an input date. However, in the software I'm using which is Blueprism, there is no modulo operator/function that is available and I can't get the result I would hope to get.
In some coding language (Python, C#, Java), Zeller's congruence formula were provided because mod is available.
Would anyone know a long method of combine arithmetic operation to get the mod result?
From what I've read, mod is the remainder result from two numbers. But 181 mod 7 = 6 and 181 divided by 7 = 25.857.. the remainder result are different.
--------------------------------------------------Disclaimer: This content was auto-posted from Stackoverflow. The original Stackoverflow question is here Stackoverflow Post, posted by erlomboy.
Answered! Go to Answer.
Helpful Answers
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
18-09-19 05:41 PM
With a Calculation Stage, you are correct, you have to use a long form expression instead. That can be achieved with the following formula.
- For example, 27 % 5 = 2, where 27 is the dividend and 5 is the divisor.
- To achieve that in a Calculation stage: [dividend] - ((RndDn([dividend]/[divisor]))*[divisor])
Cheers.
------------------------------
Charles Kovacs
Developer Consultant
Blue Prism
America/Chicago
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
18-09-19 05:41 PM
With a Calculation Stage, you are correct, you have to use a long form expression instead. That can be achieved with the following formula.
- For example, 27 % 5 = 2, where 27 is the dividend and 5 is the divisor.
- To achieve that in a Calculation stage: [dividend] - ((RndDn([dividend]/[divisor]))*[divisor])
Cheers.
------------------------------
Charles Kovacs
Developer Consultant
Blue Prism
America/Chicago
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
19-09-19 06:55 AM
Please watch the Digital Exchange for more details over the coming week.
------------------------------
Geoff Hirst
Partner Pre Sales
Blue Prism
------------------------------
