As i explained whole process of installing and using turbo c++ for a newbie. If you missed that click Here.
Let's be straight. Here is the script for creating a program that can convert price in dollars to price in rupees (Pakistani).
Script:
#include<conio.h>
#include<stdio.h>
void main()
{
float dollar,pkr,rate;
clrscr();
printf("Enter price of one dollar in Pakistani rupees:");
scanf("%f",&rate);
printf("Enter amount to convert into rupees:");
scanf("%f",&dollar);
pkr=dollar*rate;
printf("%f in Pakistani rupees = %f",dollar,pkr);
getch();
}
That's all. You can use other currency to be converted instead of dollar by giving other value when it asks for price of other currency. Remeber this script will work with Turboo C++. It can also work on other compilers too but Given is best and also very easy with user-friendly interface.
Quick Posts
applicationC languageC++ helpCalculatorDeveloping programsGuideknowledgeProfits of CTipsTurbo C++using of C
How to create a money converter to convert Dollar to Pakistani Rupess in C/C++ language.
Tags: application
, C language
, C++ help
, Calculator
, Developing programs
, Guide
, knowledge
, Profits of C
, Tips
, Turbo C++
, using of C
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment