tripleIt is a function that takes one argument and returns no value. The argument is a pointer to int. The function triples the value that the argument points to and stores it back. penalty is an int variable that has been declared and initialized. Write a statement that triples the value stored in penalty by invoking the function tripleIt. For example, if the value in penalty was 7 before your statement, after your statement its value would be 2.

LANGUAGE: C++

CHALLENGE:

tripleIt is a function that takes one argument and returns no value. The argument is a pointer to int. The function triples the value that the argument points to and stores it back. penalty is an int variable that has been declared and initialized. Write a statement that triples the value stored in penalty by invoking the function tripleIt. For example, if the value in penalty was 7 before your statement, after your statement its value would be 21.

SOLUTION:



tripleIt(&penalty);