Earlier quoted context omitted.
I'm ignorant. Who speaks Latin today under a different name?
Speakers of French, Spanish, Italian, Portuguese, Romanian, Catalan, and various other lesser-known languages and dialects. All of these are directly descended from Latin in exactly the same way that today's English is descended from 1900s English, just over a longer period.
Fortran.io – a Fortran Web Framework
221–230 of 255 posts
Re: Fortran.io – a Fortran Web Framework
#222Re: Fortran.io – a Fortran Web Framework
#223Re: Fortran.io – a Fortran Web Framework
#224The more I look at Fortran, the more I appreciate its beauty. I think some of its infamy is unjustified.
My contribution to an example of something done right in the first FORTRAN and then done wrong many times afterwards: "The March of Progress > * 1956: Fortran I: > PRINT 1, X > 1 FORMAT (F10.2) * 1980: C printf("%10.2f", x); * 1988: C++ cout * 1996: Java java.text.NumberFormat formatter = java.text.NumberFormat.getNumberInstance(); formatter.setMinimumFractionDigits(2); formatter.setMaximumFractionDigits(2); String s…
I don't know how to solve this problem. printf doesn't cut it. It simply can't specify an exact number of characters.
Re: Fortran.io – a Fortran Web Framework
#225Earlier quoted context omitted.
I studied (classical, not ecclesiastical) Latin for about 8 years, and I don't think it's accurate to claim that the Romance languages are in any meaningful sense "Latin". The weaker (and more reasonable) claim is that learning Latin improves your ability to recognize words and (very basic) structures in its descendants.
Latin and the Romance languages are indeed very different, but their similarities are much stronger than just vocabulary. The Romance languages have lost noun cases and gained prepositions, fixed word order, and definite articles, but they retain noun genders (though without neuter), remnants of the case system in pronouns ("je", "me", "moi"), many of the same verb tenses, and the subjunctive/indicative moods, to giv…
Re: Fortran.io – a Fortran Web Framework
#226Earlier quoted context omitted.
My contribution to an example of something done right in the first FORTRAN and then done wrong many times afterwards: "The March of Progress > * 1956: Fortran I: > PRINT 1, X > 1 FORMAT (F10.2) * 1980: C printf("%10.2f", x); * 1988: C++ cout * 1996: Java java.text.NumberFormat formatter = java.text.NumberFormat.getNumberInstance(); formatter.setMinimumFractionDigits(2); formatter.setMaximumFractionDigits(2); String s…
In my work life, I have a problem where I have to interface with a stringly typed API. For instance, characters 20-25 in a 400 byte string are a floating point number. No it's not a good API but I don't make decisions. So you need a six character float. "12" is wrong because it's two characters, also "12 " is invalid. "1.2e01" is wrong compared to "12.000" because it has (many) more significant digits. ".00001" is wr…
%06.*g
for width 6 down to 1.I believe this will always find an answer, and the one with the largest number of significant digits.
For example:
void format(double val, int width, char* buf) {
for (int w = width; w > 0; w--) {
int count = sprintf(buf, "%06.*g", w, val);
if (count == width) return;
}
}
"Working" example (unsafe, exits on failure, etc):Note that you can't represent negative values equal or below -1e-100 since those take 7 characters.
Re: Fortran.io – a Fortran Web Framework
#227Re: Fortran.io – a Fortran Web Framework
#228Re: Fortran.io – a Fortran Web Framework
#229Earlier quoted context omitted.
Latin and the Romance languages are indeed very different, but their similarities are much stronger than just vocabulary. The Romance languages have lost noun cases and gained prepositions, fixed word order, and definite articles, but they retain noun genders (though without neuter), remnants of the case system in pronouns ("je", "me", "moi"), many of the same verb tenses, and the subjunctive/indicative moods, to giv…
The difference between Beowulf English vs modern English and say Italian vs Latin is not the same at all
Re: Fortran.io – a Fortran Web Framework
#230Earlier quoted context omitted.
What are the highlights of Fortran's array manipulation capabilities?
Well, things like... you have 2, 2 dimensional arrays of the same size, A and B. You want to make a new array, where each cell in A is added to the same cell in B. So you are going to do a loop over 2 variables, right? in FORTRAN the code is... C = A + B in Julia the code is C = A .+ B