An accessor function that is missing a const keyword in its definition will still work as expected. However, there will be compiler errors if another member function that has been properly declared as const makes use of this function.
If you accidentally supply the const keywork in a mutator function, then a compile-time error will occur when the function attempts to modify the object's data.