59,609 views
39 votes
39 votes
The function ____ can check whether an expression meets the required conditions; if the conditions are not met, it terminates the program.

User Nattster
by
2.8k points

1 Answer

13 votes
13 votes

Answer:

assert()

Step-by-step explanation:

The assert function takes a boolean as an input, and when true, it just continues the flow, however if false it prints an error and calls exit.

User Mickey Segal
by
2.8k points