1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
#include <iostream> int cpp_sq_func(int); int cu1_sq_func(int); int cu2_sq_func(int); bool test_functions() { return (cu1_sq_func(42) == cpp_sq_func(42)) && (cu2_sq_func(42) == cpp_sq_func(42)); } int main(int argc, char** argv) { int result = test_functions() ? 0 : 1; return result; }