www.easyCPlusPlus.com

Easy C++

www.easyCPlusPlus.com

Simple Solutions in C++

Problem #1:
Problem: Write functions to calculate the minimum and maximum of a pair of numbers. Write a program that uses these functions.

Problem #2:
Problem: Write a swap function that switches the values of two integers.

Problem #3:
Problem: Write a program implementing a simple selection sort. Sort an array of integers.

Problem #4:
Problem: Write a function that uses recursion to calculate factorials. Write a program that prompts a user for a number and then calculates the factorial of that number using the function.