Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Cf or Let Calculation to check values from list without Position maybe without recursion

Featured Replies

Hello all,

still I did not fully understand how to implement recursion....

admittedly I am lost- and very much so:

There is a list of values = list

By script, I am looping through another list with keys.

Now I would like to check if the key is in the list.

First I was thinking to get the value with Position ( list ; key; 1; 1).

The problem is that in list, there might be 4651 and key might be 6, which would make Position true.

However 4651 is not 6.

Hence, I thought to loop through list by recursion and to check with the "=" but I dont know how to build this:

Let (

[

list = thelist;

k = thekey

counter = 1

c = valuecount (thelist)

];

Case ( counter > c ; "";

// this is my exit

GetValue ( list; 1) = k ; 1;

and here is am not getting the calc to recurse...

My second thought was to turn 6 into 0006 and then use Position. However the Length of the keys might change and

it seems not the right approach.

Who could help a dummy, please....

thanks

Why not do it all at once, without recursion?

FilterValues ( keys ; list )

will return a list of keys that appear in list.

  • Author

Thanks a ton- this really helped- I was really lost on this one!

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.