Does anyone have any idea on how I should proceed on making this block?

I've been thinking about how I should make this block but I'm honestly baffled. All I've managed to do so far is to split the word into separate letters without hyphens. does anyone have any idea on how I should proceed forward?

Capture

Welcome to the forums

What you could do is change your loop to go through each item in list.

Inside that loop, create a variable (e.g var1) that splits the word item into a list
Then create a check variable and set it to true

Then have another loop that compares each letter of var1 with each letter of letters one at a time and set check variable to false if any of them don't match

If they check variable is still true, then add that word to your new letters list

Hi, welcome to the forum!

I guess your class is up to Unit 2, Lab 3, huh? It's good that you're trying the Take It Further, but of course it defeats the purpose if we write it for you...

Your idea of removing the hyphens isn't a bad one; spell check programs that look for near misses, such as letters in the wrnog order, do it by sorting the letters alphabetically and looking in the dictionary for words with the same letters-sorted-alphabetically.

But that's not the problem you're solving. In that example, -e-u--c--g, you're looking for a word of exactly ten letters, with e as the second letter, u as the fourth letter, and so on. So you don't want to eliminate the hyphens, they're useful information!

If you look at the picture at the top of the page, you're going to use a KEEP like that to select words from words list. Your task is to write a predicate like the one in the gray ring in that picture. It'll look like preloaded libraries script pic.

What does it mean for two words to match? Well, look at that example again. Two words match if they're the same length and each letter of the first matches the corresponding letter of the second. "Matches" means "is equal to," except that a hyphen matches ______.

Now write it.