Social Icons

Saturday, 15 February 2014

Program to convert given inches into equivalent yard,feet and inches

#include<iostream.h>
#include<conio.h>

void main()
{
clrscr();
int y,f,i;
cout<<"\n Enter inches : ";
cin>>i;

y=i/432;
i=i%432;
f=i/12;
i=i%12;

cout<<"\n Yard = "<<y<<"\n Feet = "<<f<<"\n Inches = "<<i;
getch();
}

                                                        Output



No comments:

Post a Comment