To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 14427
14426  |  14428
Subject: 
A code by any other name
Newsgroups: 
lugnet.robotics
Date: 
Sat, 17 Feb 2001 05:00:25 GMT
Viewed: 
745 times
  
I guess that I double your output of 100,000 lines a year. I try not to call it "code"
(another trendy word) as my aim is not to encrypt anything. I call it "source text".

Your kidding?? The term "code" dates back (at least) to the "opcodes"
used in machine language (ie. an even lower level than assembly). The
term "opcode" refers to Operation Codes or "instructions" which may in
many cases have required an "operand" to work with and yes, it's
definately coded. It must be remembered that for anything to be
"perceived" (and I use the term loosely) by a computer, it must be
numerically represented, hence:  (from one of my personal favorites -
the MC68B09E)

"Compare the contents of the X register with the contents of the Y
register and set the Condition Code (CC) register accordingly, then
increment the Y register by 2"

Is in fact written as $AC (opcode) $A1 (operand) (all values in Hex)

If  "AC  A1" isn't a code, I don't know what is....

Needless to say, this is completely unintelligable to the human brain
and so we disguise it as something semi-readable.

In Assembly:
CMPX ,Y++
(a compare instruction with an indexed addressing mode)

It still isn't pretty, but it helps

In BASIC:
z=x - sample_array[y]
y=y+2

Sorry, but I don't speak C. Most of my work is in some flavour of
DBASE or Assembly, but I would imagine C is probably similar.

The point here is that higher level languages simply replace a fixed
set of commands (source code) with increasingly complex groups of
Machine Language instructions (object code). Since nothing that makes
any kind of sense to us can ever be meaningful to a machine,
everything we write is necessarily a code for something else.

I realize you probably already knew this, but I thought you might be
loosing your perspective. I always try to remember this when I'm
staring at a screen full of code that seems to make sense to me but
isn't producing the desired result. I also thought this might give a
little sense of perspective to those who aren't frequent programmers.

As for your original comment that prompted me to write this response;
I try not to call it "code" (another trendy word)
I recall back when we were writing programs on cards that the
instructions were divided into opcodes and operands and the act of
writing programs was called "coding". I suspect it started long before
I was even born. If this constitutes a "trend" then it's a really,
really, really, really long one.

It begs the question: How long does something have to exists before
you don't personally consider it a "trend".

Regards

Matthias Jetleb
VA3-MWJ
(responding via that trendy "internet" thingy)



Message has 2 Replies:
  Re: A code by any other name
 
(...) Ada Lovelace (whose Biography all programmers should read BTW) called it 'coding'. She was the very first programer who was writing programs for the (never completed) Babbage 'Analytical Engine'. She invented things like subroutines, (...) (24 years ago, 17-Feb-01, to lugnet.robotics)
  Re: A code by any other name
 
(...) And the numerical system used in computers is binary or base 2. Each instruction would have a unique binary representation providing the control of the datapath that would cause the desired action upon the data. An instruction such as (...) (24 years ago, 17-Feb-01, to lugnet.robotics)

Message is in Reply To:
  Re: What are all those lego companies?
 
(...) Tick. VG. (...) This is only due to inertia in the programming language world. Given the speed of current hardware, lexical efficiency is no longer as important as it used to be. It is quite possible to design language implementations that (...) (24 years ago, 16-Feb-01, to lugnet.robotics)

24 Messages in This Thread:









Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact

This Message and its Replies on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    
Active threads in Robotics

 
Verified and Trusted Team of Hackers
51 minutes ago
Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR