FloridaTech - College of Engineering
CSE1001 - LABORATORY

Author: Jamal Faik

Lab 3: First steps with Ada

Background


Problem 1 : Farenheit and Centigrade temperatures : Write an Ada Program that converts a centigrade temperature to its Fahrenheit equivalent. The conversion expression is :
Farenheit = 9/5 Centigrade + 32
The program should print both the centigrade temperature and its Farenheit equivalent with appropriate identifying messages. Use comments with meaningful identifiers and indentation. The program should prompt the user for the value in Centigrade then convert it to Farenheit.

Example of execution:
*************************************************************
********** Farenheit and Centigrade Temperatures ************
*************************************************************
Enter a temperature in Centigrade : 25
The correspodant temperature of 25 Centigrade in Farenheit is : 77 F.





Problem 2 (OPTIONAL): Numbers and Digits : You are to write a program that reads an integer between 0 and 999 then computes the sum of its digits.

Example of execution:
******************************************
********** Numbers and Digits ************
******************************************
Enter a number between 0 and 999 : 458
The sum of the digits of 458 is 4 + 5 + 8 = 17.