# currency8: Convert Currencies

Exercise template for converting currencies (EUR, USD, GBP) with various symbols in UTF-8 encoding.

**Name:**

`currency8`

**Type:**

**Related:**

**Description:**

Computing the worth of a randomly drawn number of shares in a certain currency. The main purpose of the exercise is to illustrate and test how UTF-8 encoding can be used in R/exams. Analogous exercises for Latin-1 and Latin-9 are also available in .Rnw format (because .Rmd requires UTF-8 only).

**Solution feedback:**

Yes

**Randomization:**

Random numbers and text blocks

**Mathematical notation:**

Yes

**Verbatim R input/output:**

No

**Images:**

No

**Other supplements:**

No

*(Note that the HTML output contains mathematical equations in MathML. It is displayed by browsers with MathML support like Firefox or Safari - but not Chrome.)*

**Demo code:**

```
library("exams")
set.seed(1090)
exams2html("currency8.Rnw", template = "plain8", encoding = "UTF-8")
set.seed(1090)
exams2pdf("currency8.Rnw", template = "plain8", encoding = "UTF-8")
set.seed(1090)
exams2html("currency8.Rmd", template = "plain8", encoding = "UTF-8")
set.seed(1090)
exams2pdf("currency8.Rmd", template = "plain8", encoding = "UTF-8")
```