Sugars are polyhydroxy aldehydes that react with themselves — and the ring that results explains almost everything they do.