I've been trying to make flash cards to help me memorize some concepts in my technical classes this semester. Since Mathematica's (mathematical) type setting is so superb, I attempted to make flash cards with it.
Some of my attempts:
1) Add group openers to input cells: Go to Format > Edit Stylesheet
. Then, if your input cell style isn't already in the stylesheet, click on the 'Choose a style' drop down menu and choose Input
. Then, with the Input
cell style highlighted, press Ctrl+Shift+E, and append ShowGroupOpener->True
to the end of the cell editor. For example, your Input
cell might look like this:
After that, press Ctrl+Shift+E again to close the cell editor, and close the stylesheet editor. Your "flash card" should now behave like this:
2) Use Button
: For flash cards whose questions are a combination of words and formulas, I use Button
(I also chose Grid
for its robust customization):
Clear[show]
SetAttributes[show, HoldAll];
show[string_String, expression_] :=
Grid@{
{string,
Defer@TraditionalForm@expression}, {Button["Show",
Print@TraditionalForm@expression], SpanFromLeft}
};
show["Calculate", Integrate[1/(x^3 + 1), x]]
One problem with this method is that if you hide the input cells (so that only the output cells containing the buttons are shown in the notebook) using this method, these flash cards behave weirdly: pressing the button again might reveal the input cell, or in subsequent pressing of the buttons, it will print out an answer that is hidden within a cell grouping (try evaluating the above example and pressing the button several times and you'll see). This is probably caused by the groupings of the print cells. Another issue is getting rid of these cells (or hide them), which I can't figure out how to do right now.
This question is supposed to encourage everyone to show your implementations of flash cards in MMA (or improving on my methods), especially ones that have helped you study in the past. Please feel free to post whatever you'd like: small self-contained flash cards, helper functions/manipulates to display flash cards based on users' input, or systematic ways to smartly organize flash cards. Let your creativity fly!
Other ideas might include: asking users to input an answer and returning True
or False
if the answer is right or wrong, randomizing the display of flash cards, and delaying a flash card if the user answers/guesses correctly on it. Anki is a good reference for good examples of flash card implementation.
tutorial/Views
. [BTW, that integral seems particularly un-flash-card-worthy. :) ] $\endgroup$