As I preach to my son--never give up, always fight for control, never stop riding your bike. Never lay it down (you can stop better with the wheels on the ground than sliding on the side of the bike)
If a crash is unavoidable, keep it under control, at least you may be able to choose what you hit and survive!