Question: what is the difference between the const and volatile qualifier in c?
Answer: volatile is used to inform the compiler not to optimise the variable. The const modifier means that this code cannot change the value of the variable, but that does not mean that the value cannot be changed by means outside this code. There are two different ways to apply the const qualifier.