Yup. PNG is 1, if JPEG were a 10 on the complexity scale (which it isn't, it is pretty simple on the absolute scale). You can understand PNG if you know a bit about algorithms, but you need a tiny bit more than high-school math to really grok JPEG.
Lossless encoding can be far simpler to understand (in some cases it's not, see FLAC).
Lossless encoding can be far simpler to understand (in some cases it's not, see FLAC).