Randomized Reading Lists for Kiddos using Bash Pipelines
Our kiddo is very good at memorizing stories and word sequences but needs to work on looking at the letters on the page. Simple bash pipelines can produce useful offline learning materials.
For example, print a randomized word list from inline story text for a book your kid loves:
#!/bin/bash tr -d '",!.-' << EOF \ | tr -s ' ' '\n' \ | sed '/^$/d' \ | sort -u \ | shuf \ | column -c 64 \ | nl \ | a2ps -1 --chars-per-line=70 --no-header The night Max wore his wolf suit and made mischief of one kind and another his mother called him "WILD THING!" ... EOFRun the script once to produce the word list. Print the source once to have the picture-less story. Carry both in your pocket on the plane/train/etc. After some work on the word list, the kid should be encouraged by "rediscovering" the picture-less story he knows using the sight words he's just practiced. In theory. Still working on the practice.
Another example, print a randomized list of kindergarten sight words:
#!/bin/bash sort -u <<EOF | shuf | column -c 64 | nl | a2ps -1 --chars-per-line=70 --no-header a about after again all always am an and any are as ask at away back ball be beautiful because been begin best big but by came can come could couldn't day did do does don't down each easy eat either enough family find for friend from fun get girl go goes going got great had has have he her here high him his home house how I idea if I'm in into is it jump just know last let like little look love make man me might mom more mother much my never next no not now of often on or our out over play pretty probably put ran read ready run said same sat saw say school see she should sit so soon special such suddenly take than that the their them themselves then there they they're things think this thought three through to today together too two under until up us very wait walk want was we went were what when where while who will with without yes you your you're yourself EOF