The teaching of programming is a difficult task, and the quality of learning obtained by the students is influenced, among other factors, by the support they receive as they solve problems. To generate hints that help students to fix the mistakes, various strategies have been implemented, primarily focused on finding differences in the obtained and expected outputs, as well as providing information from the static analysis. A method for generating hints, that besides using the above techniques includes performing dynamic analysis, supported in a specification of the inputs and outputs of the problems that allows the system to reason in terms of data types, range, distribution and correspondence between input-output pairs are presented. It was also conducted a study that has demonstrated how the developed method positively influences the number of attempts needed by the students to solve correctly the given exercises. [ABSTRACT FROM AUTHOR]