11-05-2017 01:46 AM
I am sitting the LabVIEW CLD-R exam in a few days & attempting some of the sample questions.
Question 22 has me stumped, I just don't get it.
I tried it in LV 2015, and can't seem to get the correct answer.
Can anyone explain to me whats happening here, (I generally don't use recursion, which is why I don't get it I suppose).
I will attach my attempt (that does not work..)
Thanks in advance for anyone's help
Solved! Go to Solution.
11-05-2017 03:27 AM
Just to help... attached is the actual question, just in case people don't have the exam papers.
And apparently, this is is the correct answer, (the VI attached)
Thanks
Kevin
11-05-2017 05:08 AM
Your VI-upload contains one error in comparison to the sample exam. You missed to connect the string "ExprOut". Add this to your VI:
There's also a second smaller problem with the suggested solutions from that sample exam: it is written for an environment with a dot as the decimal point. So it you use a comma as the decimal point, that's why I added explicitly the false constant to the conversion to string.
Regards, Jens
11-05-2017 02:44 PM
Very good... thank you very much.
I cannot believe I missed that... no excuse I know, but it was late at night I was trying these (so obvious now that I see it...).
Now that I see it working I get it, thanks heaps.
Kevin
11-19-2018 06:52 AM
Hi you guys.
Still I can´t get why answer D is the right one. Probably something related to recursive function? I was learning about this but still can´t get the reason why D is right.
Can anyone help me?
11-19-2018 07:45 AM
11-19-2018 07:57 AM
Thanks Jeff, but, opción B also stops recursing the VI. so whats is different there?
11-19-2018 09:08 AM
@pcortes2 wrote:
Thanks Jeff, but, opción B also stops recursing the VI. so whats is different there?
The only real difference I am seeing is the Result double being stored in a shift register. I would need to spend a lot more time going through the code to figure out if it really should be there or not (my current thought is NO).
11-19-2018 09:30 AM
@crossrulz wrote:
@pcortes2 wrote:
Thanks Jeff, but, opción B also stops recursing the VI. so whats is different there?
The only real difference I am seeing is the Result double being stored in a shift register. I would need to spend a lot more time going through the code to figure out if it really should be there or not (my current thought is NO).
You are thinking correct. The result of the incurred step is the output of the case. so the loop output is not what you want as the result.
11-19-2018 02:02 PM
Thanks !!!