ASSIGNMENT #3
Control Structures

Reference material


    Please solve only one exercise!

  1. Write a program that finds the minimal enzyme activity in each of the tissues mentioned in Assignment 2.2:
    brain: 65, 69, 70, 63, 70, 68.
    heart: 102, 95, 98, 110.
    lung: 112, 115, 113, 109, 95, 98, 100.

  2. Write a program that asks the user to enter two odd numbers, and prints all odd numbers between them (including the entered numbers), in descending order.

    If the entered numbers are not odd the program should only print an error message.

    Hint: Use if, and for.

  3. Write an iterative subroutine that computes N factorial. The program should ask the user for an integer number N, and output N!

    The program should return an error message if the entered number is not a positive whole number.


Important


Course Home Page.