assign2 - Assignment 2 Manipulating Numeric Data EE312 -...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Assignment 2 Manipulating Numeric Data EE312 - The University of Texas at Austin – Spring 2010 Assigned: Monday, Feb 1st Due: Thursday, Feb 11 th , before midnight. Value: 20 points (18 for correctness and 2 for good style) File submitted: Submit (upload) the final version of your C source code file (.c file) to the Blackboard’s assignment manager for this assignment in your section of this course. Purposes: · to learn how to input and output numeric values using formatted IO commands · to learn how to define and symbolically manipulate numeric data · to learn how to use program control statements to perform looping and decision making · to hone your problem solving and program development skills Background: Let’s pretend that we are planning a trip to Dublin, Ireland in the near future. Ireland uses different measurement systems than the US does. So, in order for us to be able to travel around Dublin and understand the quantities that are represented there, we need a conversion program (e.g. on our laptop) that will help us with the following: 1. Dublin time to Austin time and vice versa (so that we know when to call home) 2. US $ to Irish monetary units and vice versa (so we know how much we are spending) 3. Degrees Fahrenheit to Degrees Celsius and vice versa (so we know how hot it is) 4. Kilograms (metric system) to US pounds and ounces and vice versa (so that we know how much things weigh) 5. Kilometers (metric system) to US miles and vice versa (so that we know how far we have to go) You will write a C program to do these conversions for any legitimate given value. The following sections describe the conversion rules and requirements for each category above. Part 1. Time Check out http://www.worldtimezone.com/ if you need help figuring it out. You may use a 24-hour clock to simplify the conversions. Your program will convert a given specific Austin time to Dublin time; be sure to output an appropriate day-change notice (e.g. day before, or day after) if needed with each answer. Your program will also convert a given specific Dublin time to Austin time; be sure to output an appropriate day-change notice (e.g. day before, or day after) if needed with each answer. In both cases above, the input will be given as two whole numbers: the hour number and the number of minutes, and the output will also be two whole numbers. For example, currently Austin is on CST and Dublin is on GMT – when it is 9am our time, it is 3pm the same day in Dublin (i.e. Dublin time = Austin time + 6 (modulo 24)). Part 2. Money
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 03/15/2010 for the course EE 16005 taught by Professor Krasner during the Spring '10 term at University of Texas at Austin.

Page1 / 4

assign2 - Assignment 2 Manipulating Numeric Data EE312 -...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online