5062CEM

Programming and Algorithms 2

Functions in C++

Functions in C++

For this activity, you will need to be using an Integrated Development Environment (IDE). The recommended IDE for this module is JetBrains IntelliJ IDEA for Python and JetBrains CLion for C++. You can follow instructions at the following page to set up your development environment:

Setting up your Development Environment

Create a function that accepts two variables, these variables can either be an integer or floating point. You will then need to sum these two values together and return the total sum.

Create a function that accepts two numbers, and return the maximum of the two numbers.

Create a function that accepts two numbers, and return the maximum of the three numbers.

Hint

For this task you may want to use the previous function you have implemented to aid in the completion of this solution.

If you are struggling with this lab activity, you may want to get some additional support. You can speak to the module leader/team in the room of when the lab week is active, or you can visit the Additional Support page for more information on how you can get extra support.