Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

OutSystems Exam Associate-Reactive-Developer Topic 1 Question 18 Discussion

Actual exam question for OutSystems's Associate-Reactive-Developer exam
Question #: 18
Topic #: 1
[All Associate-Reactive-Developer Questions]

Consider the following Action (https://drive.google.com/file/d/1L6qUwd2jjqWAluUB-Kv5gQghendWoMr2/view?usp=sharing), that calculates the square root (sqrt) of a positive decimal number (N). Knowing that the function was called with N = 0, and the debugger is stopped at the Start node, what will happen when the developer selects the Continue (F9) option highlighted in the picture?

Show Suggested Answer Hide Answer
Suggested Answer: C

Contribute your Thoughts:

Susana
16 days ago
I'm going with option B - it's gotta throw an exception. I mean, come on, dividing by zero? That's like the first thing they teach you in programming 101. Although, I'd love to see the developer's face if the debugger just shrugged and stopped at the N < 0 node. That would be a real 'mic drop' moment.
upvoted 0 times
Demetra
2 days ago
I think it will throw an exception too. Dividing by zero is a big no-no.
upvoted 0 times
...
...
Chantell
22 days ago
Option D seems like the safest bet. The debugger will stop at the breakpoint in the End node, which is the responsible thing to do. But you know what they say, 'expect the unexpected' - maybe the action will just explode and leave the developer scratching their head.
upvoted 0 times
Rosita
3 days ago
I think option D is the most likely outcome.
upvoted 0 times
...
...
Lisha
1 months ago
Hmm, I'm leaning towards option C. If N is 0, the debugger should stop at the N < 0 node, right? That's the logical choice. Although, I can't help but wonder if the developer secretly programmed in a surprise ending where the action just ends with sqrt = 0.
upvoted 0 times
Delbert
1 days ago
I agree, that seems like the logical outcome based on the information provided.
upvoted 0 times
...
Lisha
19 days ago
I think option C is the correct choice. The debugger will stop at the N < 0 If node.
upvoted 0 times
...
...
Jerlene
1 months ago
I think option B is the way to go. Dividing by zero is a big no-no, so it's gotta throw an exception. Although, it'd be pretty funny if the debugger just stopped at the N < 0 node instead. What is this, amateur hour?
upvoted 0 times
Yvonne
16 days ago
Yeah, throwing an exception makes sense. Can't have undefined values floating around.
upvoted 0 times
...
Wenona
21 days ago
Well, we'll have to wait and see. It could go either way.
upvoted 0 times
...
William
26 days ago
I'm not so sure, I think the debugger might just stop at the N < 0 node instead.
upvoted 0 times
...
Suzan
26 days ago
I agree, option B seems like the most logical choice. Dividing by zero is a definite no-go.
upvoted 0 times
...
Nell
29 days ago
Yeah, I think so too. It's a common mistake that would definitely throw an exception.
upvoted 0 times
...
Anglea
1 months ago
I agree, option B seems most likely. Dividing by zero is a definite exception.
upvoted 0 times
...
...
Shelton
1 months ago
Well, if N is 0, then the square root should be 0, so option A seems correct. But I wonder what happens if N is negative - will it throw an exception or just stop at the N < 0 node?
upvoted 0 times
...
Janna
2 months ago
But if N = 0, the sqrt should be 0, so I think A is correct.
upvoted 0 times
...
Nana
2 months ago
I disagree, I believe the correct answer is A.
upvoted 0 times
...
Janna
2 months ago
I think the correct answer is B.
upvoted 0 times
...

Save Cancel