With Bash, keeping a task simple often means using several different tools that all do their jobs well. Here's an easy, effective way to create a notification for when your laptop is unplugged.
Designed for students, the BBC micro:bit, in conjunction with MicroPython and the Mu editor, can help you get started with microcontroller programming.