I recently had to build an infrared close proximity sensor that could tell if something was dropped in a parcel delivery drop box.
Some readers may recall building a line-following robot during their school days. Involving some IR LEDs, perhaps a bit of LEGO ...