Re: OK what does ` mean - seriously seems to be not documented.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Sometimes the explanations are more complicated than the issues they are explaining.

All computers store text as numbers. At their core, numbers are all that a computer understands. It is up to a human to give contextual meaning to those numbers.

Some programming languages abstract this idea away and the number of data types proliferate. One reason for this is that it makes it easier for the interpreter or compiler to flag logic errors earlier in the development process. However, it can also make less expressive and/or more verbose. It takes away some flexibility on the part of the programmer.

Euphoria simplifies this: every piece of data is either a number, a list of numbers, or a list of lists of numbers. How those numbers are interpreted is completely up to the programmer. Some numbers can be interpreted as human readable text instead of their literal value. There exists some conventions, such as ASCII/ANSI/Unicode, as well as different internal representation (and slightly different behavior) of integral values vs. real values.

However, the abstraction still works and makes many routines generic. Whereas in some programming languages you have to write a different function for each different kind of value that it can take as input, or worse, have to write ugly templating code, in Euphoria your functions can generally take one kind of input, perform an operation, and produce the correct output.

For input and output, Euphoria routines try to guess whether any given piece of data can be interpreted as text or as a numerical value. That's a tool for the programmer to decide to use.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu