What is an exhaustive as possible list of examples of floating-point literals as they are written in source code?
That is, the float is not parsed from a text file with arbitrary floats.
The float literal must is written in correct syntax for a programming language such that one or both of the following:
- the computer language is mainstream today.
- the computer language was main-stream in the past.
double-precision is allowed, single-precision is allowed, any precision is allowed, base 16, base 8, etc...
If you understand the question, then you can stop reading the question now.
The string representation you provide for floating point must be used by the parser, or interpreter, or compiler for source code in one or more language which is well-used in the present or was well-used used in the past such as java-script, HTML, python, C++, Fortran, Intel x86 assembly, Java, etc...
If the terms "mainstream" and "well-used" are too subjective for your taste, then the following list might help:
Intel x86 Assembly language
Fortran
C
Java
ABAP
ABL
Ada
Assembly
Awk
Bash (Bourne Again Shell) script
C
C#
C++
CFML
COBOL
D
Dart
Delphi/Object
F#
Fortran
FoxPro
Go
Groovy
Haskell
Java
JavaScript
Julia Kotlin
Lisp
Logo
Lua
MATLAB
Objective-C
OpenEdge
Perl
PHP
PL/SQL
PowerShell
Prolog
Python
R Ruby Rust
SAS Scala Scheme Scratch SQL
Swift
Transact-SQL
TypeScript
Visual
Visual Basic
Zig
This is a publicly editable wiki, so feel free to add more to it.