On the functions

On this post we will check one of the first things I published, fun whit numbers if you want to check it again do it here: https://etomanue.wordpress.com/2017/02/02/fun-whit-numbers/, the difference whit that post is that now its going to be done whit functions.

As a reminder the program ask for two numbers and returns:

  • The sum of the two numbers.
  • The difference of the two numbers.
  • The product of the two numbers.
  • The integer based division of the two numbers (so no decimal point). First divided by second.
  • The remainder of integer division of the two numbers.

Captura de pantalla 2017-03-16 a las 10.56.38 a.m.

As you can see the math is done on the functions and the results are printed later on the last lines of the program (19, 20, 21).

Captura de pantalla 2017-03-16 a las 10.55.57 a.m.

and thats it. This is basically an exercise to practice how to do functions. Thanks for read my blog again 😃 😄.

 

 

3 comentarios en “On the functions

Deja un comentario