Independence Day Deal! Unlock 25% OFF Today – Limited-Time Offer - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Salesforce Exam Javascript Developer I Topic 2 Question 71 Discussion

Actual exam question for Salesforce's Javascript Developer I exam
Question #: 71
Topic #: 2
[All Javascript Developer I Questions]

Which two code snippets showworking examples of a recursive function?

Choose 2 answers

Show Suggested Answer Hide Answer
Suggested Answer: C

Contribute your Thoughts:

Whitley
1 months ago
Wait, is this a test on recursion or a stand-up comedy routine? I'm ready to bring the house down with some recursive jokes!
upvoted 0 times
...
Tracie
1 months ago
Aha! I've got it. A and D are the winners here. Time to show off my recursive superpowers!
upvoted 0 times
Wynell
9 days ago
User 2: Agreed, those two show working examples of recursive functions.
upvoted 0 times
...
Arlean
10 days ago
User 1: I think A and D are the correct answers.
upvoted 0 times
...
...
Carlee
1 months ago
Hold up, is this a trick question? I feel like I'm about to get recursion-wrapped and thrown down a rabbit hole.
upvoted 0 times
...
Augustine
1 months ago
Hmm, B and C seem a bit off. I'm pretty sure they're not quite recursive enough. Time to put on my thinking cap!
upvoted 0 times
Reuben
5 days ago
D) Const factorial =numVar => {If (numVar < 0) return;If ( numVar === 0 ) return 1;returnnumVar * factorial ( numVar - 1 );};
upvoted 0 times
...
Dean
19 days ago
A) Let countingDown = function(startNumber) {If ( startNumber >0) {console.log(startNumber) ;return countingDown(startNUmber);} else {return startNumber;}};
upvoted 0 times
...
...
Helene
2 months ago
Ooh, A and D look like they'll do the trick! I can almost smell the recursion working its magic.
upvoted 0 times
Alverta
1 months ago
D) Const factorial =numVar => {If (numVar < 0) return;If ( numVar === 0 ) return 1;returnnumVar * factorial ( numVar - 1 );};
upvoted 0 times
...
Thea
2 months ago
A) Let countingDown = function(startNumber) {If ( startNumber >0) {console.log(startNumber) ;return countingDown(startNUmber);} else {return startNumber;}};
upvoted 0 times
...
...
Mary
2 months ago
I'm not sure, but I think A and D make sense because they call themselves within the function.
upvoted 0 times
...
Kimberlie
2 months ago
I agree with you, Novella. A and D seem to be recursive functions.
upvoted 0 times
...
Novella
2 months ago
I think options A and D are the correct ones.
upvoted 0 times
...
Afton
2 months ago
I'm not sure about option A, but I think option D is definitely a recursive function. It calculates factorial by calling itself with a smaller number.
upvoted 0 times
...
Ty
2 months ago
I agree with you, Lindsay. Option A uses recursion to count down, and option D calculates factorial recursively.
upvoted 0 times
...
Lindsay
2 months ago
I think options A and D are the working examples of recursive functions.
upvoted 0 times
...

Save Cancel
az-700  pass4success  az-104  200-301  200-201  cissp  350-401  350-201  350-501  350-601  350-801  350-901  az-720  az-305  pl-300  

Warning: Cannot modify header information - headers already sent by (output started at /pass.php:70) in /pass.php on line 77