You are on page 1of 1

F0RM No. ITM-FRM-66 (Rev.

00)

ITM UNIVERSITY, Gurgaon


School/ Department
: CSE&IT
Subject Name
: FOCP-II
Subject Code
: CSL108
Unit/Title: Pointer and structure, pre-processor directives

REVIEW DATE:
Tutorial Sheet No. 3
Issue Date:
23-01-2015
Faculty : Sandeep Singh

Page:
1/ 1
Sem: II

1. Create a structure to represent the complex number. Write functions for add and
multiply operations on two complex numbers.
2. Define a structure to store date, month, year, hours, minutes, second and time zone.
Create an array of this structure for 5 elements. Select any five time zone to represent
five countries and show the current time in that time zone based on the current local
time. Create appropriate functions to update the time in the array.
3. Write a function to calculate the total experience and age of an employee. Date of
joining and date of birth are passed to the function. Suitable structure can be made to
store date in date, month and year format. Age and experience should be in the form
of Date, month and year.
4. Write down macro definitions for the following:
a. To find arithmetic mean of two numbers.
b. To find absolute value of a number.
c. To convert a uppercase alphabet to lowercase.
d. To obtain the bigger of two numbers.