Thursday, September 25, 2014

Day 6 - 2: Pass by value

1. Write a function which accepts an integer value as input, and returns an integer which is the cube of that input

2. Write a function that accepts a char as input and returns true if the char is a digit from 0 to 9 or false if the character is not a digit from 0 to 9


3. Write a function named Smallest that takes three integer inputs and returns an integer that is the smallest of the three inputs.  Write the prototype for the Smallest function.  Write  a program that gets 3 integers from a user and displays the smallest.

4. Write a function that, given a letter of the alphabet, returns true if the letter is a vowel (lower or uppercase) and returns false if the letter is not a vowel.

No comments:

Post a Comment