user
Programming languages have different ways of expressing floating-point literals.

Task

Show how floating-point literals can be expressed in your language: decimal or other bases, exponential notation, and any other special features.

You may want to include a regular expression or BNF/ABNF/EBNF defining allowable formats for your language.

Related tasks

* Literals/Integer
* Extreme floating point values
assistant
(formerly Perl 6)
Floating point numbers (the Num type) are written in the standard 'e' scientific notation:

```
2e2      # same as 200e0, 2e2, 200.0e0  and 2.0e2
6.02e23
-2e48
1e-9
1e0

```

A number like 3.1416 is specifically not floating point, but rational (the Rat type), equivalent to 3927/1250. On the other hand, Num(3.1416) would be considered a floating literal though by virtue of mandatory constant folding.