Pages: 1 [2]   Go Down
Author Topic: Philosophical debate on language leads to question  (Read 2127 times)
0 Members and 1 Guest are viewing this topic.
Central Indiana, USA
Offline Offline
Full Member
***
Karma: 0
Posts: 202
So many projects, so little time...and money!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

@lefty--how true it is!
Logged

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Are there compilers that work in other languages ?

i mean, as far as I know, C language (and every other programming language I 've encountered) is basically English.   And a rapid search with the help of our googly friends didn't tell me more.

All they have to do is a cut and paste from English to another language concerning the commands of any language.
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 98
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Compilers are lexographic translators, the do not working in "English", it just so happens that some of the lexographic symbols 'resemble' English words.
Much of the language has its basis in mathematics.

Whilst you may say " for (int loop=0; loop<8; loop++)" ,it is no more English than "Typhoon" (大風) or "Sampan" (三板).
For it to be English then you should be looking at:

Can you please loop round the following:
......
whilst the count is less than 8.

HC


Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 27
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Under that logic everything typed that does not conform to the exact rules of the language, ceases to be english.

consider : " I ARE A CAT " is not english , sure lexographically teh words are all english, but as a sentence it isn't.

( and that typo in 'the' ruins my sentence too, as does lack of capitalising and puntucation  )

INT ( eger ), FOR, LOOP, WHILE, and so on are all english words... that's the point
« Last Edit: February 03, 2012, 06:03:19 am by tomperdarwin » Logged

Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 240
Posts: 24441
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Changing keywords/reserved words in a programming to match the native language is relatively simple, but imagine, for instance, COBOL in German, with the verb at the end!   smiley-grin
Logged

"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

CO, USA
Offline Offline
God Member
*****
Karma: 4
Posts: 710
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Changing keywords/reserved words in a programming to match the native language is relatively simple, but imagine, for instance, COBOL in German, with the verb at the end!   smiley-grin

I once worked with a guy who figured out how to modify the symbol table in the CDC COBOL compiler so that his most frequent typos would still work. This was just for fun, of course, because you don't send code to production with 'perfrom' instead of 'perform' scattered here and there. Hmmm, might have been under VMS -- we were using both, and that was back in the early 80s, so I don't remember the gory details.
Logged

... it is poor civic hygiene to install technologies that could someday
facilitate a police state. -- Bruce Schneier

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I've wondered about that for a while, but in the end I think it doesn't make a huge difference, if you speak English natively or not. Even for English speakers, C initially looks pretty obscure, for example:

Code:
^      exclusive or
%      modulus
++     add 1 to itself
--     subtract 1 from itself
&      bitwise and
|      bitwise or
&&     logical and
||     logical or
~      negate  (plus destructor)
{ }    group stuff into a block
!      not <something>
< >    templates
#xx    some obscure compiler directive
\xx    some "escape" sequence
void   huh?
int    a number?
char   a letter?

It's not as if a native English speaker can pick up C++ code and just know exactly what it means. And for non-English speakers, they just have to add a few more things to the list, like "if" and "while". And even English speakers have to learn stuff like "if (a = b)" won't work as you expect.
Logged

Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 240
Posts: 24441
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Even mathematicians have big problems with C
Code:
x = x + 1;
is clearly nonsense!
Logged

"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Just subtract x from both sides, AWOL, then it becomes clearer:

Code:
0 = 1

Oh, wait ...
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 443
Posts: 23834
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

No problem, at that point you just multiply both sides by a number that allows you to get an engineering estimate where boths sides have a common numerator ....

0 * 0 = 0 * 1

Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Problem solved. smiley
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 331
Posts: 16540
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I find software humor void().

Logged

Pages: 1 [2]   Go Up
Jump to: