Answer
#pragma once tells the compiler to include a file only once, achieving the same effect as #ifndef guards with less boilerplate and no risk of guard-name collisions. It's non-standard but supported by all major compilers. Its rare edge case is with the same file reachable via different paths/symlinks; traditional guards are fully portable.
#pragma once // top of header, instead of #ifndef guardsReal-world example Most modern headers use #pragma once for brevity, falling back to guards only where strict portability is required.