Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add else statements to True and False Execise #221

Open
mbdunn opened this issue Jun 19, 2019 · 2 comments

Comments

Projects
None yet
2 participants
@mbdunn
Copy link

commented Jun 19, 2019

The True and False Statements exercise in the Making Choices lesson would be more clear with some else statements to display the results when the value is considered false.
For example:
if [ ]
disp('empty is true')
else
disp('empty array is false')
end

Also, when learning I found the use of "foo" everywhere in examples confusing and frustrating, using a word that means something to people might make it more accessible.

@gcapes

This comment has been minimized.

Copy link
Contributor

commented Jun 20, 2019

Thanks for the ideas @mbdunn!
A PR with some else statements would be welcome!

I don't feel too strongly either way about 'foo'. We only have one example of it in this lesson, but it is widely used in programming as a meaningless placeholder for variable and function names, strings etc, precisely because it holds no meaning. See here for further info https://en.wikipedia.org/wiki/Foobar

@mbdunn

This comment has been minimized.

Copy link
Author

commented Jun 26, 2019

Great thanks! I'll give the PR thing a try.

Good point. I guess giving a bit of background and introducing it while teaching would help because it will be everywhere when they need to look stuff up for themselves after.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.