Answer to Question #173815 in C for Arslan habib

Question #173815

Make a program in c language using switch statement is currency converter.

Pak rupees to dollars.

Pak rupees to pound.

Pak rupees to dirham.

Pak rupees to sterling.


1
Expert's answer
2021-03-20T16:00:30-0400
#include <bits/stdc++.h>
using namespace std;


int main()
{
    float pak_currency, dollar, pound, dirham,sterling;
    
    cout<<"Enter Pakistaani Currency: ";
    cin>>pak_currency;
    
    dollar = pak_currency * 0.0064;
    pound = pak_currency * 0.0046;
    dirham = pak_currency * 0.024;
    sterling = pak_currency * 0.0046;
    
    cout<<"Pakistani Currency in Dollars: "<<dollar<<endl;
    cout<<"Pakistani Currency in Pound: "<<pound<<endl;
    cout<<"Pakistani Currency in Dirham: "<<dirham<<endl;
    cout<<"Pakistani Currency in Sterling: "<<sterling<<endl;
    return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS