Obtenha soluções detalhadas no IDNLearner.com. Pergunte qualquer coisa e receba respostas completas e precisas de nossa comunidade de profissionais especializados.

Given the following function declaration: findMax(): return max(5, 7) What is wrong with the function?

Sagot :

Resposta:

The function `findMax()` is missing a return type and does not include a return statement. It should be written with a return type specified (e.g., `int`), and the `return` keyword should be used to return the result of `max(5, 7)`.