View Full Version : Basics of Computer
ITlover
01-01-2005, 03:40 AM
I have started this thread for the discussion regarding basics of Computers.
We know that the function of computers is based on digital signals (0 or 1).
But what is algorithms? Is algorithm the same as digits or is it something different?
What role does algorithm plays in the internal function of a Computer?
Lets discuss....................
Have a Nice Day and Wish all of you a Happy New Year.
WhatsThisBoxFor?
01-01-2005, 06:45 AM
Algorithm: http://www.webopedia.com/TERM/a/algorithm.html
ITlover
01-01-2005, 07:26 AM
I'll check this site and return with my comments.
Regards,
foolishone
01-01-2005, 02:42 PM
I don't mean to get off the question on the floor, but in what field of study, or maybe some member here can tell me how does the computer know to ignore words and what to do with them in programming? Easy example in Visual Basic, a For loop:
For x=0 to 4
Shape(x).FillColor = red
Next x
How does it know what the heck a for is, nevermind means? Does it store a variable with the present value and then at the end adds/subtracts the interval to the stroed varialbe. How does it know after 1 its 2, and after 2 its 3...?
^fo
Colonel Sanders
01-01-2005, 03:56 PM
Visual basic is a compiled language, what you code is not the same as what the machine sees.
What the machine uses is called machine code, try studying the basics of assembly language to better understant machine code. Assembly language consists of stuff like "MOV AX,5h". That little line of code moves the value 5h (h for hex) into the register AX. By itself, that code is useless. There are other commands in assembly that allow for addition, subtraction, multiplicatinand division, and not a whole lot more. Assemlby is close to machine language, but machine language is far more cryptic and not human readable.
The ability to count is built into the CPU's circuitry. Understanding a for loop requires several lines of machine code.
Also, most compilers add extra stuff that isn't necessary. Assembly code is the longest way to write a program (you get to control everything but the end result will be more optomised. BUT, I'd recomend you stick to visual basic, I myself like C, but anything (except machine code) will be easier to code than assembly. ;)
L J
foolishone
01-02-2005, 11:39 AM
Thank you Colonel Sanders, that was just what I was looking for.
^fo
Coding in assembly produces the most efficient programs. Just ask Steve Gibson (grc.com) - and look at some of his work. You really have to be a geek to be able to do this, though - he's been doing this stuff for many years.
vBulletin® v3.7.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.