Q.Write a program that take dollar currency as
input and display output in NC and IC.
Program:
#include<stdio.h>
#include<conio.h>
void
main()
{
float
DC, NC,IC;
printf(“enter
the dollar currency=”);
scanf(“%f”,&DC);
NC=DC*100;
IC=NC*16;
printf(“\ncurrency
in Nepal is=%f”,NC);
printf(“\ncurrency
in India is=%f”,IC);
getch();
}
Output:
enter
the currency in dollar=2
currency
in Nepal is=200
currency
in India is=32.0
No comments:
Post a Comment