If the micro:bit runs out of resources or detects a fault, it enters a 'panic' routine which displays a sad face on the micro:bit screen followed by a number eg 020.
There are a list of errors on the microbit.org website with descriptions of what they mean and what you can do to fix. In all cases, pressing the reset button on the back of the micro:bit will restart the program, which clears out the RAM memory and starts again.
If you are using C++, then these errors are more likely if you have a bug in your C++ program.
The Javscript Blocks Editor builds on these and adds additional information eg 042
Keywords for search: sad face, error, error codes, panic code, 020, 050, 051