{{^^%F0%9F%92%AC^^}} We discussed: {formmenu:Earth's spheres;Scientific investigation; Theories vs. laws; Scientific measurement; Atomic Structure and Forces; Chemical vs. physical changes; name=topics; multiple=yes; formatter=items -> join(items, "BLAZE_AND")}.
{{^^%F0%9F%8C%9F^^}} What You Did Well
{if:{=topics}="Earth's spheres"} {formmenu: name=spheres; Clearly explained how energy and matter transfer between Earth's major spheres.; Thoughtfully analyzed how a change in one Earth sphere triggers ripple effects across the others.; Gave great examples of how various spheres interact with each other!} {elseif:{=topics}="Scientific investigation"}{formmenu: A;B;C} {elseif:{=topics}="Theories vs. laws"} {formmenu: A;B;C} {elseif:{=topics}="Scientific measurement"} {formmenu: A;B;C} {elseif:{=topics}="Atomic Structure and Forces"}{formmenu: A;B;C} {elseif:{=topics}="Chemical vs. physical changes"}{formmenu: A;B;C}{endif}
The If statement under What you did well is not working, and I don't know why.
The if statement from your code isn't working because its condition attempts to compare a list against individual strings. Since topics is a list defined by the formmenu command in the first line, you can instead check if it contains a certain item with the includes function.
For example, instead of {= topics} = "Earth's spheres", you could write includes(topics, "Earth's Spheres").
I hope this helps! Let me know if you have any other questions.
Okay. I got it to work with that snippet, but now this section from a different snippet is not working. The electromagnetic waves option works, but not the other options work. I tried using includes and the contains, and they both work for the electromagnetic waves, but not the other options. What am I missing?
Time to grow your understanding of: {formmenu: name=typesimprove; ; electromagnetic waves; mechanical waves; longitudinal waves; transverse waves; electromagnetic spectrum; multiple=yes; formatter=items -> join(items, "BLAZE_AND")}
Opportunities for Growth
Every gap we identify is just a roadmap for what to master next. I encourage you to review : {if: contains({=typesimprove}, "mechanical waves")}
Mechanical waves require a medium to travel through. {endif}{if: contains({=typesimprove}, "electromagnetic waves")}
Electromagnetic waves can travel through a vacuum. {endif} {if: includes({=typesimprove}, "longitudinal waves")}
Longitudinal waves have particles that move in the same direction as the wave. {endif}{if: contains({=typesimprove}, " transverse waves")}
Transverse waves have particles that move at right angles to the direction of the wave. {endif}
Time to grow your understanding of: {formmenu: name=typesimprove; electromagnetic waves; mechanical waves; longitudinal waves; transverse waves; electromagnetic spectrum; multiple=yes; formatter=items -> join(items, "BLAZE_AND")}
Opportunities for Growth
Every gap we identify is just a roadmap for what to master next. I encourage you to review: {if: includes(typesimprove, "mechanical waves")}
Mechanical waves require a medium to travel through. {endif}{if: includes(typesimprove, "electromagnetic waves")}
Electromagnetic waves can travel through a vacuum. {endif}{if: includes(typesimprove, "longitudinal waves")}
Longitudinal waves have particles that move in the same direction as the wave. {endif}{if: includes(typesimprove, "transverse waves")}
Transverse waves have particles that move at right angles to the direction of the wave. {endif}
@AshwinMittal As you may see, I came up with a similar solution in the other thread but used contains rather than includes. Is there any benefit in using one over the other. Thanks, Tony
When multiple=yes is used in a formmenu, the result is a list. You'll want to use includes for that. contains is meant for checking if a string contains a specific substring.