//any function can throw an errorfunction functionWithException() { throw new Error("test exception");}functionWithException();