1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
snow_lady [41]
3 years ago
13

2) Please create a C program for the following: (25 points) a. Suppose the US dollar to Korean Won is 0.85 dollars to 1000 won.

Ask the user how many won is currently within their wallet / purse. Print out how much the Won is worth in US dollars, Indian Rupee (0.014 to the dollar), Jordanian Dinar (1.41 to the dollar) and Mexican Peso (0.048 to the dollar). You may also add another country of your choosing.
Computers and Technology
1 answer:
Zanzabum3 years ago
3 0

Answer:

In C:

#include <stdio.h>

int main(){

       float won,usd,rupee,dinar,peso;

       printf("Won: ");

       scanf("%f", &won);

       usd = won * 0.85/1000;

       rupee = won * 0.85 * 0.14/1000;

       dinar = won * 0.85 * 0.048/1000;

       peso = won * 0.85 * 1.41/1000;

       printf("USD = %f\n", usd);

       printf("Rupee = %f\n", rupee);

       printf("Dinar = %f\n", dinar);

       printf("Peso = %f\n", peso);

   return 0;

}

Explanation:

This declares all variables as float

float won,usd,rupee,dinar,peso;

This prompts the user for Korean Won

       printf("Won: ");

This gets the input for won

       scanf("%f", &won);

This converts to usd

       usd = won * 0.85/1000;

This converts to rupee

       rupee = won * 0.85 * 0.14/1000;

This converts to dinar

       dinar = won * 0.85 * 0.048/1000;

This converts to peso

       peso = won * 0.85 * 1.41/1000;

The next four lines print the converted currencies

       printf("USD = %f\n", usd);

       printf("Rupee = %f\n", rupee);

       printf("Dinar = %f\n", dinar);

       printf("Peso = %f\n", peso);

You might be interested in
There are 40 houses if company y provides electricity to 2/5 of the houses how many houses as company y provide electricity to
yulyashka [42]
The article for the assignment I need help with part 2xexbixneixe
6 0
3 years ago
You have one IP address provided from your ISP with a /30 mask. However, you have 300 users that need to access the Internet. Wh
DedPeter [7]

Answer:

A. PAT.

Explanation:

Based on the detail given the technology I will

basically use to help implement the solution will be PAT which full meaning is PORT ADDRESS TRANSLATION reason been that PAT is a technology that enables multiple users to have access to the internet and secondly PORT ADDRESS TRANSLATION (PAT) can often share one IP public address to multiple or different internet users at a time.

8 0
3 years ago
20.
SpyIntel [72]
2Na hope that helps  ^^;
6 0
3 years ago
Read 2 more answers
What time is spellrd the same forwards and backwards​
Juliette [100K]
12:21 is the correct answer
6 0
3 years ago
Most operating systems perform these tasks. coordinating the interaction between hardware and software allocating RAM to open pr
goldenfox [79]

Answer:

The answer are A.) Coordinating the interaction between hardware and software And B.) Allocating RAM to open programs

Explanation:

Hope this helps :)

5 0
3 years ago
Other questions:
  • What is the correct order of network types when categorized by their size or the physical area they cover, from largest to small
    5·1 answer
  • Walt needs to ensure that messages from a colleague in another organization are never incorrectly identified as spam. What shoul
    14·2 answers
  • The hotspot created by MiFi is password protected and can be used to connect Wi-Fi devices located within ____ feet of the MiFi
    9·1 answer
  • Write a code block to encode strings from original messages, using our custom encoding. To do so: Initialize a variable called c
    6·1 answer
  • Which of the following is the best name for a history report about world war 1
    7·1 answer
  • Malcolm Movers charges a base rate of $200 per move plus $150 per hour and $2 per mile. Write a program named MoveEstimator that
    5·1 answer
  • C. Explain the given term in short:<br>a. Computer Ethics​
    14·2 answers
  • _ is a term used for license like those issues by creative commons license as an alternative to copyright
    8·1 answer
  • What action should you take if you become aware that sensitive compartmented information has been compromised
    14·1 answer
  • Given main(), complete the Car class (in files Car.h and Car.cpp) with member functions to set and get the purchase price of a c
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!