Exposure Java 2007 Chapter 1

64
Chapter I Introduction to Computer Science Chapter I Topics 1.1 Teaching the Exposure Way 1.2 Exposure Equation 1.3 Roller Coaster Emotions 1.4 Tackling Computer Science 1.5 Excessive Help 1.6 Computer Fundamentals 1.7 A Brief History of Computing 1.8 How Do Computers Work? 1.9 Messages with Morse Code 1.10 Electronic Memory 1.11 Counting in Other Number Systems Chapter I Introduction to Computer Science Page 1.1

description

The first chapter of Leon Schram's Exposure Java textbook.

Transcript of Exposure Java 2007 Chapter 1

Chapter I Introduction to Computer ScienceChapter I Topics1.1 Teaching the Exposure Way1.2 Exposure Equation1.3 Roller Coaster Emotions1.4 Tackling Computer Science1. Excessi!e "elp1.# Computer $un%amentals1.& ' (rie) "istory o) Computing1.* "o+ ,o Computers Work- 1.. /essages +ith /orse Co%e1.10 Electronic /emory1.11 Counting in 1ther 2um3er Systems1.12 /emory an% Storage1.13 What 4s 5rogramming-1.14 5rogramming 6anguages1.1 2et+orking1.1# "ar%+are an% So)t+are1.1& SummaryChapter 4 4ntro%uction to Computer Science 5age 1.11.1Teaching the Exposure WayOneofthemost important elementsoflearninginaclassroomisthestudentteacher relationship. Who claims that? Me, Leon Schram, a computer scienceteacher for more than twenty years. If you are a studentat !ohn "aul II #ighSchoolreading this $oo%, your suspicions were correct.Something happened toMr. Schram $ac% in the Si&ties when he was in 'ietnam. (ou might suspect toomuch e&posure to )gent Orange?It has pro$a$ly caused some $rain cell damage.(ou %nowthe slow dissol*ingone $raincellatatime %ind of damage.Ma%essense, it has $een a$out +, years since 'ietnam and this guy is acting *ery weirdthese days.Many years ago I learned -uite a lesson a$out relationships with students.I had ayoung lady in my class who had trou$le with math..o, let me $e honest, this girlwas pitiful with any type of mathematical pro$lem.Our school had some type oftalent show and I went to see it.I was a$solutely $lown away./his girl,my bless-her-will-she-ever-learn-math-student, had the *oice of an angel. She wasanimated, shewasincredi$lytalented, andsuddenlyIsawherdifferently. /hattalent show %noc%ed me straight out of my tunnel*ision*iew of a struggling mathstudent.I told her the following day how impressed I was with her performance.She $eamed and was so pleased that I had noticed.Something neat happened afterthat. Sure, she still agoni0ed in math $ut she wor%ed, and tried, harder than shehad done pre*iously. )t the same time, I tried harder also. /he teacher1studentrelationship,whichhadde*eloped, madehera$etterstudentanditmademea$etter teacher.I ha*e $een a teacher for a long time, and I ha*e $een a student for e*en longer.)s a teacher, and as a student, I ha*e seen my share of $oo%s that hardly e*er getopened. Students try hard to learn. #owe*er, they do not get it, get $ored, getdisinterested, get frustrated, feel stupid, are intimidated .... pic% your poison./he$oo% 2ust sits somewhere and $ecomes useless..ow this particular $oo% may $ethe most informati*e, most complete, most uptodate, most correct $oo% on thesu$2ect, $ut if the $oo% sits and occupies space, the content matters little.#ow does an author of a $oo% de*elop a studentteacher relationship? /hat istric%y $usiness, $ut if you are really curious what I loo% li%e, try my we$ page athttp://www.schram.org. It ismyaimtowritethis$oo%inthefirstpersonusing an informal, *er$al styleof communication. I want to tal% to you, ratherthan write to you.3y the way, I do not recommend this writing style for 4nglishtype teachers. I will guarantee you that they are neither amused nor impressed.My 4nglish teachers certainly ha*e ne*er cared much for my writing style and Iha*e $een told at many occasions that my writing lac%s the scholarly fla*or oneassociates with college style writing.5or one thing, one does not use I, one usesone. 6o you %now how $oring it is to %eep saying onedoes this and onedoesthat?Well, I do not %now what one does, $ut I do %now what I do, so I will %eepusingIandwe. /hisisnot forthesa%eofglorifyingmyself,$ut to%eepan5age 1.2 Exposure 7a!a8 200& E%ition 0*91*90&informal style.Students ha*e told me in the past that it appears that I am tal%ingto them.In fact, I ha*e $een accused of writing with an accent.In case you all donotreali0e it I was neither$orn in /e&as nor the7nitedStates. Iwas$orn in#olland, mo*ed all o*er the place, ended up in the 7nited States, too% a test in4nglish,7Sgo*ernment and7Shistory,andthen$ecamean7Sciti0en. Si&months after my new citi0enship I was rewarded with an alle&pensespaid trip to'ietnam. /oday, I ha*e forgotten se*eral languages I learned in my youth, and Icannot spea% any language I remem$er without an accent.) few more items on this personal relationship $usiness.I was$ornin 89:,. Iha*e $een married to the sweetest wife in the world since )pril 9, 89;73)di*ing, tra*elingandwriting. .ow there is a slight pro$lem. (ou %now a little a$out me, $ut I %nownothing a$out you.Well perhaps we will meet one day, and I may also hear a$outyou from your teachers.3y the way, there is a way that I can get to %now more a$out you.(ou can dropme an email line..ow please read this carefully.(ou may wish to send me a noteand sayhi. (ou might e*en want to gi*e me some constructi*e criticism a$outthese $oo%s. #owe*er, do not write and as% for ad*ice on programs that do notwor%. (ou ha*e a computer science teacher. (our teacher %nows yourassignments, %nowsyour$ac%ground, and%nowsyourcomputer sciencele*el.(our teacher can help you far more effecti*ely than I possi$ly can at a distance.)nother point, I get fre-uent email from students re-uesting to $uy some of these$oo%s that you are reading.I do not pu$lish paper copies for sale.School districtspurchase a copy license, and each school district uses their own method for ma%ingcopies.(ou can approach your teacher a$out ac-uiring copies from them, if that isan option at your school.=ood, now that we ha*e that straight, let me mo*e on.(ou may get the impression that all this informal style, and such, may ta%e awayfrom the serious $usiness of learning computer science. 6o not $elie*e that forone minute./here are many pages ahead of you and each topic is going to get athoroughtreatment.)lsodonot thin%, 2ust $ecausethisintroductionislighthearted, that e*erything will $e in the same style.Some topics are duller than dirtand you will 2ust ha*e to digest some discomfort and ma%e the $est of it. Othertopics are pretty intense, and I will do my $est to ma%e it clear what is happening,$ut there are no promises.I will try hard to do my part and you need to do yours.!ust e&actly what you need to do to learn will come a little later in this chapter.Chapter 4 4ntro%uction to Computer Science 5age 1.31.2Exposure EquationSomewhere during the time when >roMagnum Man told the .eanderthals to ta%ea hi%e$asically my early /wentiesa neat Sociology professor said something*ery interesting.What he said ended up ha*ing a profound attitude on my teachingandmywriting. #eclaimedthatnothinginlifeisobvious, andhetoldthefollowing story.Imagine a young boy in the Amazon jungles. This boy has always lived in thejunglewithoutanymodernconvenience. Hehasneverbeeninacity,hehasnever seen a television nor seen a book.Now imagine that or reasons unknownthis young boy travels to !olorado in the "intertime. The little boy stands in ayard somewhere and watches the snow with bewilderment. He is astonished# hedoes notunderstand whatisalling rom the sky. Anotherlittle boy, about thesame age, rom !olorado, looks at the boy$s behavior.The young !olorado boydoes not understand the other boy$s bewilderment."hy is the boy acting so odd,obviously it is snowing, so what is the big deal%/he )ma0on $oy is $ewildered./he >olorado $oy is confused that the other $oyis $ewildered. /he professor as%ed us what the difference $etween the two $oysis, and use only one word to descri$e that difference./he word is . . . . . .E!"S#$E/he point made $y my sociology professor was so wonderfully simple and logical.If you ha*e 0ero e&posure to something, you will $e $ewildered.If you ha*e ne*erinyourlifeseenaplane,heardaplanefly$y,seenapictureofaplane,heardany$ody tal% a$out a plane, you will $e one frightened, confused puppy when thefirst plane comes $y.#ereareacouplemoree&amples. WhenI cametothe7nitedStates, Ihad$rea%fast the way most )merican did. I poured myself a $owl of cereal, usually>orn 5la%es, and then proceeded to warm up some mil% on the sto*e./he warmmil% was then poured o*er the >orn 5la%es.)s someone who grew up in 4urope,it was ?o$*ious? to me that warm mil% is what you put on cereal.I found it *erystrange when I reali0ed )mericans put cold milk on cereal.Many years later, I am on a cruise with my son !ohn. )n 4nglish couple sittingacross from us loo%s at my son and the following dialog transpires@4nglish Man@ ?I say sir, what is that??5age 1.4 Exposure 7a!a8 200& E%ition 0*91*90&!ohn@ ?What is what??4nglish Man@ ?/hat sir, what is that??A#e points to !ohnBs drin%.C!ohn@ ?6o you mean my iced tea??4nglish Man@ ?Iced /ea?Iced /ea?=ood Lord Mildred.6id you e*er hear of such a thing.?4nglish Woman@ ?My word, no #enry.I thin% I should li%e to try some of that.?/he point trying to $e made with these e&ample is that e&posure theory states thatnothing in life is o$*ious.What we do ha*e are *arying degrees of e&posure./hismeans the ne&t time some$ody says@ &It is 'ainully obvious to see the outcome othis situation,( do not get e&cited./ranslate that statement into@ &ater being e)'osed to this situation or the last *+years o my lie, and having seen the same conse,uences or the same *+ years, itis now easy or me to conclude the outcome.(Well, this good sociology professorI wish I remem$ered his name and could gi*ehim creditimpressed me with his o$*ious$ewildermente&posure theory.3asedon his theory I ha*e created an e-uation@%ewi&derment ' Exposure ( ")*ious/his e-uation states that bewilderment is where you start.With 0ero e&posure itis not logical to immediately comprehend a new concept, let alone consider it to $eo$*ious.#owe*er, let enough e&posure come your way, and yes, you too will findsomething o$*ious that was confusing at the first introduction. /his means thatyou need some special sympathy for your first instructor and your first $oo%. Iha*e had that theory wor% for, and against me. Students ha*e come to me andsaid, it made so much more sense to me when it was e&plained in college.I ha*ehad the opposite claim with, if only my first instructor had e&plained it as well asyou did I would not ha*e had so much trou$le. So2ustwhat isthepointhere?Something*eryweirdhappenswithacademiclearning. Students, andI meanstudents of allpossi$leages, inall%indsofacademic topics, e&pect understanding on the first goaround.Students open their$oo%s, andwithsomeluc%readatopiconce. "erhapsasecond, $riefreadingoccurs immediately $efore an e&amination.)nd more than once, I ha*e $een toldChapter 4 4ntro%uction to Computer Science 5age 1.you told us that yesterday when I am repeating an important, pro$a$ly confusing,point that re-uires repetition..ow let us switch the scene to athletics, $and, orchestra, cheerleading and the drillteam.#ow many $and directors practice a halftime show once?#a*e you heardof any drill team directors sending girls home after they rehearsed their routine forthe first time?Seen any$ody on the swim team get out off the pool after one laplately, claiming that they %now that stro%e now? #ow a$out $as%et$all players?6o they -uit practice after they ma%e a $as%et?6o the cheerleaders -uit the firsttimetheysucceed in$uildinga pyramid?(ou%nowthe answers to these-uestions. Intheareaof e&tracurricularacti*ities, students getexposedtoodeath.)s a matter of fact, some of this e&posure is so fre-uent, and so se*ere thatstudents are luc%y to ha*e any time left o*er for some $asic academic e&posure.3ut guys, learning is learning and it does not matter whether it is physical, mental,andartisticor e*erythingcom$ined. (oucannot learnanythingwellwithoute&posure. )nd yes, in case you ha*e not noticed $y now, I $elie*e so strongly inthis philosophy that Icallthese $oo%s-)'osure .ava2ustli%emy pre*ious te&t$oo% that was called -)'osure !//.I amharpingonthistopic$ecauseI$elie*ethat somany,many,studentsarecapa$le of learning a challenging su$2ect li%e computer science. /he reason thatthey -uit, fail, or hardly e*en start is $ecause they interpret their $ewilderment asan indication of their aptitude, their ina$ility to learn.One little introduction, oneshort little e&posure and a flood of confusion o*erwhelms many students. 5ine,this is normalD welcome to the world of learning.Let me $orrow from my fa*orite sport, s%iing. I ha*e watched a whole $unch ofpeople learn to s%i.I ha*e ta%en many students on s%i trips and I ha*e taught a fairnum$er of people of different ages to s%i. (ou %now, I ha*e ne*er seen any$odyget off the lift for the first time and car*e down that $unny slope li%e an Olympics%ier. I ha*e seen many people stum$le off the lift wondering what to do ne&t. Iha*e watched these $randnew s%iers as they s%i down for the first time all $endo*er,out of$alance,s%isfloppinginthe$ree0e, polese*erywhere, andusuallytotally out of control. ) close encounter with the snow normally follows. 5ine,you did not loo% so swell on the first time down, or e*en the first day, or may$ethe first trip. )fter peopleEs first taste of s%iing, I ha*e seen many determined toen2oy this wonderful sport and I ha*e watched as they made fantastic progress.Iha*e also seen other people who -uit after minimal practice, and concluded theywerenot capa$leof learningto s%i. .ormally,the$oring, o$ligatorylist ofe&cuses comes attached free of charge./his means whether you are a high school student, learning computer science forthefirsttimeorateacher,learning!a*aafter>FF,youcanlearnthismaterial.(ou can learn it well, e*en with surprisingly little pain, pro*ided you do not selfinflict so much permanent pain with all this $usiness of selfdou$t and I cannot dothis or I cannot do that.So you are confused.(ou do not understand?=reat, 2oin the crowd $ecause thema2orityoftheclassisconfused. Openyour mouth, as%-uestions, hear the5age 1.# Exposure 7a!a8 200& E%ition 0*91*90&e&planationasecondtimearoundandallowtimetoflowthroughyour $rain./here is not a channel you can change ... a $utton you can push ... a pill you canta%e... or aspecialist youcanpay,to soa%up%nowledgeeasily.(ouneede&posure, and surprise ...exposure takes effort. )s% a champion swimmer howmany laps they ha*e completed? )s% any$ody who is accomplished in any fieldhow they arri*ed. Let me %now if they arri*ed on day one. I want to meet thate&traordinary person.1.+$o&&er Coaster Emotions.o$ody,inmye&perienceasacomputer scienceteacher, e&pressedtherollercoaster emotionsof computer science learning $etter than #oward Smith.#oward is not his real name, $ut the young man may not li%e to see his name inprint. ) typical encounter in the computer la$ with #oward went something li%ethis.Mr. SchramGG Mr. SchramGG I lo*e computersG I am going to $e a computerscientistG>omputers are so coolG/his e&citement would normally follow somesegment of #owardEs assignment thatwor%ed correctly. 7nfortunately, #owardwassoonfacedwithanuncooperati*ecomputer inthene&t stage. 5re-uently,there were pro$lems, and #oward could $e seen in the la$ 2umping up and downas he e&claimed, Mr. Schram, I hate computersG I donEt want to touch anothercomputer. >omputers hate me. Mr. Schram, I want to drop this course. I wantoutGI want out now, this minuteGI hate, hate, hate computersG5ew people show emotions to the degree that #oward did, $ut he did illustrate a*ery importantpoint. /hereisnothingsteadya$outlearning computerscience.(our timeinthe computer la$isprimarilyde*otedto ma%ingthe computerperform some assigned tas% correctly. (ou will e&perience the e&citement whenthe computer responds correctly and you will also e&perience the frustration whenyour computer 2ust does not cooperate./histypeofemotionis so differentfromstudying a history$oo% orwriting anessay. 4ssays do not go through stages of wor%ing and not wor%ing. )n essayslowly and steadily $ecomes $etter and e*en when your essay is far from perfect,you may decide to turn it in anyway. ) computer program can ha*e some smallglitch and will not wor% at all.Is this so $ad?It is not $ad at all and I ha*e seenthousands of students learn computer science *ery successfully. I am mentioningthe roller coaster feelings $ecause I ha*e o$ser*ed it and it may $e of help for youto reali0e that such feelings are *ery common.)fter you gain confidence, you mayfind that learning computer science is *ery rewarding and can $e -uite a $it of fun.Chapter 4 4ntro%uction to Computer Science 5age 1.&1.,Tac-&ing Computer ScienceStudentsha*eall%indsofdifferent learningandstudyapproaches. (oumustaccept one simple fact.Learning computer science, li%e learning most la$ sciences,is most effecti*e when you disco*er an important concept./eachers can gi*e youtheorems, general laws and all %inds of facts a$out some scientific discipline.(et,theselawswerealldisco*ered$yscientistsastheyo$ser*edawide*arietyofdifferent situations./he same philosophy will $e used in the -)'osure $oo%s.(ou will see many, manysmall programs. Most programs will focus on one or two concepts. Study eachone of the program e&amples carefully. >hec% to see what the e&amples ha*e incommon.Hemem$er that reading and studying program e&amples has limited results. (ouneed to get your hands dirty. /ype in the program e&amples. O$ser*e how theprograms wor%.>hange some of the program statements $y adding, deleting andalteringsome of the information. /he more you ?play? with the programstatements, the $etter your understanding will grow.Steps In .earning Computer Science Rea% the assigne% text3ook pages 3e)ore the lecture. Closely listen to the lecture.4n particular8 )ocus on any concepts that +ere con)using %uring your rea%ing. 4) program examples are use% at your computer8 make surethat you are at the same place as the lecture. 5lay +ith the computer.6oa% or type small program examples an% try %i))erent approaches. 5age 1.* Exposure 7a!a8 200& E%ition 0*91*90& 'sk questions8 i) you are con)use%.Concentrate yourquestions on the topic 3eing %iscusse%. Rea% the material again a)ter the lecture )or continuingexposure./ake note o) any topics that are still con)using. Rea% the la3 assignments 3e)ore arri!ing )or a sche%ule%la3.Think a3out the solution. Work on the la3 assignment.'sk )or help +hen you arestuck./ake sure to gi!e clear questions. /ake sure that you get clari)ication in any area thatis con)using )e/ore you take a test. 5ay particularly close attention +hen a test is returne% an%your teacher goes o!er the questions. 5lease reali:e that cramming %oes not +ork +ith computer science.;ou nee% the com3ination o) text 3ook rea%ing8 lectureomputer science students learn not only from their teachers, they also can learn agreat deal from fellow students. Sometimes, the $est teacher for you may $e theperson who has 2ust disco*ered a solution to the pro$lem that is also frustratingyou./henameofthegameislearning, andlearningcomesinmanydifferentforms with many different types of teachers.One day understanding clic%s in your$rain when you try something on the computer ... another day it may $e a teacherEsstatement in a lecture ... perhaps you read a chapter in your te&t $oo% again ... andcertainly it can $e the help of a fellow student."rogramassignmentsareaconsidera$lepart ofyour grade. /eacher policiesfluctuatetremendously$utyoura$ilitytofinishcomputerla$assignmentsisanintegral part of your total grade. (ou need to recogni0e that an easy temptationpresents itself.#ow a$out simply copying the la$ assignment from a good $uddyor some$ody who is a$out to $ecome your good $uddy?(ou %now some nice %idwho appears to $e pretty smart and always finishes the assignment $efore you do./here are two ma2or pro$lems with this approach@ It is wrong $ecause it is unethical. It is wrong $ecause you are not learning.Ifyoudonot reali0ethat copyingotherpeopleEswor%withor without theirconsentis wrong, then it is time you discuss this issue with your parents to getclarification on $asic issues of right and wrong.>omputer la$ assignments, that can $e copied, are only a part of the total gradepicture. (ou also ha*e to ta%e written tests and you ha*e to ta%e computer la$tests. If students study together, help each other with la$ assignments, and if thestudents learnfromtheir studygroup, theywill learnanddo fineontests.Students who put in 0ero effort do not learn and fail tests misera$ly./hoseofyouwhoareinclinedtohelpyourfriends$ylettingthemcopyyourefforts need to consider the type of friend that you are.) true friend will teach andprepare a $uddy for upcoming -ui00es and tests. Some$ody who li%es the -uic%5age 1.10 Exposure 7a!a8 200& E%ition 0*91*90&popularity thatcomes with improperdis%copying allows a friend to failinthefuture.Excessi*e 1e&p,o not get excessi!e help. ,o not copy la3 assignments. 4t is+rong.;ou kno+ it is +rong8 an% you +ill not learn.,o )orm stu%y groups. ,o +ork together an% help each otherun%erstan% %i))icult concepts. ,o encourage your )rien%s +henthey are struggling.1.2Computer 3undamenta&s=etting started with computer science is none too easy. /he course that you areta%ing, and the $oo% thatyou are reading, assumes that this is your first formalcomputer sciencecourse. 5urthermore, it isalsoassumedthat youha*eno%nowledge of programming.If you do %now some programming, fine, $ut it is notany %ind of a prere-uisite./his means that we should start at the $eginning.#owe*er, does the $eginning mean an e&planation li%e@ this is a monitorD that is a'rinterDhereisthe'owerbuttonDthereisthenetworkserver?"ro$a$lynot./odayEs high school students usually ha*e $een $ehind a *ariety of computers sinceelementaryschool. Manystudentsha*eheardstoriesonhowcomputersma%eman%indEs life simpler. 6id you %now how long it used to ta%e to fill out uselesspaperwor%?/oday we can finish ten times the useless paperwor% in a fraction ofthe old time with the aid of computers. "rogress is good. )nyway, this chapterwill pro*ide a $rief computer history and pro*ide some information a$outcomputer components, networ%ingandrelatedtopics. #owe*er, theprimaryfocus ofthischapterwill$eonunderstandinghow thecomputerwor%s.Whatma%es it tic%?#ow does it store information?#ow does it manage to calculate,and how is information stored? )nd, what is a program anyway? In general, allthe introductory information necessary to start learning programming.1.4 5 %rie/ Computer 1istory6It is easy to write a *ery fat $oo% strictly on the topic of computer history. It isalso a ma2or snoo0e topic for most teenagers.Many young people en2oy wor%ingwith computers, $ut listening to a stimulating lecture on the history of computers isChapter 4 4ntro%uction to Computer Science 5age 1.11another story. In manycases incominghighschool students ha*e learnedcomputer history in middle school technology classes.It does seem odd to plungeinto a computer science course without at least some reference towhere did thiscome rom anyway% What follows is a chronology of some of the ma2or steps inthe historyof computers. /hereare many,manysignificant largeandsmallcontri$utions that are not mentioned./his at least is a small start. The '3acus8 3000 (.C./he)$acus was originallyin*entedintheMiddle4asternarea. /hisratherama0ing computing de*ice is still *ery much used in many )sian countries today.S%illed )$acus handlers can get $asic arithmetic results 2ust a$out as fast as youmight get with a fourfunction calculator.2apier (ones8 1#1&!ohn .apier used some $ones mar%ed with special scales to simplify arithmetic $yusing addition for multiplication and su$traction for di*ision. It set the stage forthe slide rule.Sli%e Rule8 1#22WilliamOughtred created the slide rule. /his de*ice allows sophisticatedmathematical calculations, which was widely in use until around 89omputer>ompanyiscreatedandintroducesthe )ppleIIpersonal>omputer.It $ecomes the first commercially successful personal computer.Tan%yommodore and /andy start selling personal computers./he >ommodore and the)pple computer re-uire a tele*ision interface to *iew computer operations. /he/andy HadioSha% computer has its own >H/ AmonitorC.?isiCalc8 1.&.6an3ric%lincreated'isi>alc,aspreadsheet program, which$ecomesthefirstwide spread software to $e sold.6an 3ric%lin initially li*ed in a hut somewhere inthe mountains of Montana and recei*ed an a*erage of M+I,III.II a wee% for hisin*ention. #edidnot $enefit fromthetremendous $oominthespreadsheetmar%et, $ecause his software could not get a patent.Chapter 4 4ntro%uction to Computer Science 5age 1.1Wor%Star8 1.&.Micro"roreleases WordStar, which$ecomesthemost popularwordprocessingsoftware program.4(/ 5C8 1.*1I3M introduces the I3M ".>. It is a computer with a monochrome monitor andtwofloppydri*es. #arddri*esarenot yet a*aila$lefor personal computers.I3MBsentryintothepersonalcomputer mar%et gi*esthepersonalcomputer aserious image as a true $usiness computer and not some sophisticated electronicgame playing machine./S9,1S8 1.*1I3M decides not to create its own operating system for the personal computingmar%et and decide to outsource de*elopment of its operating system for its tri*iallittle personal computer department. Manycompanies re2ect I3Mproposal.Microsoft, anun%nownlittlecompanyrun$y3ill=ates, agreestocreatetheoperating system for the I3M "ersonal >omputer and $ecomes a company largerthan I3M./acintosh8 1.*4)pple starts tosell the )ppleMacintosh computer. /he mousetechnology wasalready de*eloped earlier $y Oero& >orporation and )pple actually introduced thistechnology with its Lisa computer in 89LN./he Lisa computer costs M8I,III andis a commercial failure./he ?Mac? was the first commercially successful computerwith the mouse1windows technology.6aptop 5Cs8 1..1Most "> *endors start to sell laptop ">s./he early laptops all ha*e monochromemonitors and lac% the power and memory storage of des%top computers.5age 1.1# Exposure 7a!a8 200& E%ition 0*91*90&Win%o+s 3.18 1..2Microsoft introduces Windows+.8, whichisitsfirst ma2or windowssoftwareseller.It is a Windows type interface, $ut it is $ased on the 6OS operating system.Win%o+s .8 1..8 @.S.Microsoft introduces Windows 9,, which now is an operating system similar to theMacintosh computer.The 6ast Ten ;earsSince899,there has $eenane&plosioninpersonal computers withgreatermemory,fasterprocessors, largerharddri*es,L>6monitors, laptopcomputersthat ri*aldes%topcomputersincapa$ility,computernetwor%ingwithwireandthen wireless connections and the use of the Internet in incredi$ly large num$ers./he irony of computer progress is that e*en the e&perts ha*e $een *ery wrong intheir predictions. In 89:; when the first fullyelectronic computer,the4.I)>,was created, it was stated that the world would ne*er need more than ten 4.I)>s.(ears later at thetimewhenmost personal computers had;:I,III3ytes ofmemory, 3ill=ates announced that personal computers will not need more than;:I,III $ytes of memory./his chapter is written on a personal computer with one=iga3yteofmemory,whichis8,III,III,III$ytesofmemory. (oumaynot%nowpreciselywhat one$yteis,$ut 8,III,III,III$ytesisawholelot morememory than ;:I,III $ytes of memory.(et, your children will $e ama0ed at theprimiti*e machines you are using right now, $ecause their future cell phones andwrist watcheswillha*emorepower andmemorythanthedes%topandlaptopcomputersha*etoday.4*enthecheapest cellphoneonthemar%et todayhasmore power than the M8I,III,III 4.I)> computer had $ac% in 89:;. 1.7 1ow 8o Computers Wor-6 #uman $eings do not spend money on e&pensi*e items unless such items somehowimpro*e human capa$ilities.>ars are great./hey mo*e faster than humans, theydonot get tired, andthey%eepyoucomforta$lein$adweather. /heyaree&pensi*e, $ut the e&pense is worth it.>omputers process information and do thisChapter 4 4ntro%uction to Computer Science 5age 1.1&processing $etterinmany areascomparedtohuman $eings. /hethreeareas inwhich a computer is superior to a human $eing are shown in figure 8.8.3igure 1.1Three 5reas Where Computers %eat !eop&e Computers are )aster Computers are more accurate Computers %o not )orget(ou may $e -uic% to accept thatcom'uters are aster,$ut you are notso surea$out the other two./oo often you ha*e heard the term com'uter error and youalso remem$er hearing a$out data that was lost in the computer.Well, let us start our computer lesson right now $y clearing up some $asic myths.!om'uters donot makeerrors.Sure, it ispossi$lefor acomputer to gi*eerroneous information. #owe*er, the computer isnothing $uta stupid machinethat faithfully, and always accurately, follows instructions.If the instructions gi*en$y a human $eing to a computer are faulty, then the computer will produce errors.)t the same time, many socalled com'uter errors are caused $y sloppy data entry.) person who recei*es an outrageous electric $ill is told that the computer createdan erroneous $ill. /rue, the computer printed the $ill, $ut not until a dataentrycler% had slipped an e&tra 0ero in the amount of electricity used for the pre*iousmonth."erhaps youarestillnot con*inced. )fter all,whata$out thesituationwhen acomputer $rea%sdown?WonEt that causepro$lems?3ro%encomputerswillcertainlycausepro$lems.#owe*er,yourcomputerwillnot wor%at all. (ourcomputer applications will not wor% and you are stuc%, $ut the computer does notsuddenly start adding 2 + 2 = 5.(ou may also ha*e heard that people lose their computer information $ecause ofpro$lems with dis% dri*es.Once again this happens, $ut computer users who %eeptheir computers anddis%ettes inaproper en*ironment, alongwithasensi$le$ac%up system, do not ha*e such pro$lems.Well,yougi*eup..opointarguingwithastupid$oo%that cannot hearyou.5ine, the computer is aster, the computer is more accurate, and sure the computerdoes not orget.3ut how is this managed electronically?(ou %now that electricityis incredi$ly fast, and you ha*e e*ery confidence that the flip of a switch turns on alight or a *acuum cleaner. /odayEs computers are electronic, and 2ust how doeselectricity store inormation?#ow does a computer perform com'utations?#owdoes a computer translate %ey$oard stro%es into desira$le output? /hese are all5age 1.1* Exposure 7a!a8 200& E%ition 0*91*90&good -uestions and an attempt will $e made here to e&plain this in a manner thatdoes not $ecome too technical.1.9:essages with :orse Code7nless you area3oyScoutor.a*y sailor,you pro$a$ly ha*e little e&periencewith Morse code./odayEs communication is so much $etter than Morse code, $utthere was a time when Morse code was an incredi$le in*ention and allowed *eryrapid electronic communication.Imaginethefollowingsituation. Somehow,youha*emanagedtoconnect anelectricwire$etweenthehomeofyour friendandyourself. (ou$othha*ea$u00erandapush$utton. 4achoneofyouiscapa$leof$u00ingtheotherperson, and the $u00er ma%es a noise as long as the $utton is pressed. (ou ha*enomoneyforamicrophone, youha*enoamplifierandyouha*enospea%ers.5urthermore, your mean parents ha*e grounded you to your room without use ofthe telephone.3ut you do ha*e your wires, your $u00ers and your $uttons.>anyou communicate? (ou certainly can communicate if you %now Morse code orde*elopasimilarsystem. Morsecodeis$asedonaseriesofshortandlongsignals./hese signals can $e sounds, lights, or other sym$ols, $ut you need somesystemtotranslatesignalsintohumancommunication. Morsecodecreatesanentire set of short and long signal com$inations for e*ery letter in the alpha$et ande*ery num$er.7sually, a long signal is three times as long as a short signal.In thediagram, $elow, a long signal is shown with a $ar.) short signal is indicated $y as-uare. >onsider the first fi*e letters in the Morse code system, shown in the figure8.N ta$le.3igure 1.23irst 3i*e .etters In :orse Code5 ; ;;; short 9 long% ;;; ; ; ; long 9 short 9 short 9 shortC ;;; ; ;;; ; long 9 short 9 long 9 short8 ;;; ; ; long 9 short 9 shortE ; shortChapter 4 4ntro%uction to Computer Science 5age 1.1.(ou,andyour$uddy,cannowsendmessages $ac%and forth.3ypressingthe$u00er with long and short sounds.Letters and num$ers can $e created this way.5or instance the word BAD would $e signaled as follows@AAA A A AA AAAAAA A A/he secret of Morse code is the fact that electricity can $e turned on, and it can $eturned o./his means that a flashlight can send long and short $eams of light anda $u00er can send long and short $u00ing sounds.With an esta$lished code, suchas Morse code, we cannowsendcom$inations of longandshort impulseselectronically. 'ery,*ery$riefpausesoccur$etween theshortsand longsofaletter.Longer pauses indicate the separation $etween letters./his $asically meansthat electronically we can send human messages $y turning electricity on and off inaseriesoforgani0edpulses. 6oesthismeanthat SamuelMorsein*entedthecomputer? .o, he did not get credit for starting the computer re*olution, $ut itdoes ser*e as a simple e&ample to illustrate how electricity can process letters $ytranslating on and off situations into letters and num$ers.1.1omputer Science,means on and ! means off.3igure 1.+o// on o// o// o// o// o// on< 1 < < < < < 15age 1.20 Exposure 7a!a8 200& E%ition 0*91*90&In this particular e&ample, the secondand eighth $ul$s are on, and all the otherlights are off./his represents only one of 256 different com$inations.5igure 8.,will show three more com$inations. It certainly is not Morse code, $ut using theMorsecodee&ample,we canimagine that each one ofthe N,;com$inationsisassigned to a letter, a num$er, or some other type of character./he num$er system you use is base"!. >ounting and computation in $ase 8I isnot simpler than other $ases $ecause it is $ase 8I. It is simpler $ecause you use$ase8I. Soundsconfusing, doesitnot?Inelementaryschool, youpracticedmultiplication ta$les in $ase 8I. #ow many multiplication ta$les did you practicein $ase , or $ase L?.ot too many, right?Humor has it that people de*eloped a$ase 8I system, $ecause of our ten fingers..ow in $ase 8I digits range from ! to#.)fter the largest digit #, we must use two digits, li%e !, , 2, $, % etc. tocount higher.Mathematically spea%ing, counting and computation is possi$le in many different$ases.) num$er system that is *ery s%impy in digits is base"2.Only the digits !andare used.Many digits are needed for e*en small*alued num$ers./he first+N num$ers in base"2, with the e-ui*alent base"! *alues are shown in figure 8.:.3igure 1.,%ase 1< %ase=2 %ase 1< %ase=20 0 1# 100001 1 1& 100012 10 1* 100103 11 1. 100114 100 20 10100 101 21 10101# 110 22 10110& 111 23 10111* 1000 24 11000. 1001 2 1100110 1010 2# 1101011 1011 2& 1101112 1100 2* 1110013 1101 2. 1110114 1110 30 111101 1111 31 11111.ow consider these three Llight$ul$s com$inations in figure 8.,.4ach one of these com$inations of on and off light $ul$s can $e *iewed as a base"2 num$er.Chapter 4 4ntro%uction to Computer Science 5age 1.213igure 1.00 1 0 0 0 0 0 1"7withashort codefore*erytypeoftas%performed$ythe>"7. 4*ery>"7instruction had a mnemonic name.5or instance, mov AX,1234 is the instructiontoplacethe*alue8N+:intotheA7 register. /heA7 registerisatemporarycalculation scratch pad in the >"7. )ssem$lyLanguage $rought anotherimpro*ement $y using he&adecimal A$ase8;C num$ers rather than $inary A$aseNCnum$ers./here e&ists a uni-ue relationship $etween $aseN and $ase8; num$ers,such that any set of fourdigit $aseN num$ers can $e represented $y one $ase8;num$er.It is certainly easier to wor% with onefourth the digits.) programmer first wrote a set of instructions in the special )ssem$ly Languagecode./his code was then translated $y a socalled )ssem$ler./he )ssem$lertranslated the mnemonic short word instructions into machine code that could $eprocessed $y the computer.!rogramming with Interpreters and Compi&ers)ssem$ly Language started the $all rolling.) computer program had $een createdtoma%e the2o$ofcreating a machinelanguageprogramsimpler. /hisprocessChapter 4 4ntro%uction to Computer Science 5age 1.31could $e continued and a more sophisticated program could translate a programthat is *ery similar to human language.One person, who must $e mentioned, is thelate 8race 9opper. =race #opper was a lieutenant in the .a*y when she firstwor%ed e&tensi*ely with computers. She was largely instrumental for de*elopingtranslating programs that allow programming in a humanstyle language.She wasone of the main de*elopers of the popular program language, >O3OL, and was*ery influential in the de*elopment of early translators./wo types of translating programs were created, interpreters and compilers.)ninterpreter ta%es a program and translates the program one line at a time. )ftereachlineis translated, the resultingmachinecode is e&ecuted. )compilertranslates the entire program into a machine code file and then e&ecutes the file.Itis easier to create an interpreter, $ut the e&ecution speed is slower than a compiler.) compilerisfarmorecomple&tocreate, $ut ite&ecutesmuchfasterthananinterpreter. /he ma2ority of todayEs programlanguages use compilers fortranslators. /he language you will learn, !a*a, oddly enough is $oth a compiledand an interpreti*e language.#ow this is possi$le will $e e&plained soon..ow=.e*e& and 1igh=.e*e& !rogram .anguagesLanguages that are*erycloseto computer $inarycode arecalledlow"le:el.Machine code and )ssem$ly Language are lowle*el languages. Languages thatare closer to human languages are called high"le:ellanguages. Some languagesare *eryhighle*el today, and manyprogrammingtas%s ha*e already$eenperformed. Withmanylanguages, itispossi$letoclic%anddragonprogramo$2ects that ha*e already $een created and insert them inside your program.So why not simply write your programs in 4nglish?Is that not a matter of creatingsome%indoftranslatingprogramthat ta%es4nglishinstructionsandcreatesamachine code file for the computer?/his is certainly what has $een attempted formany years, $ut translating human languages has $een *ery elusi*e.>onsider thefollowing e&ample.In the si&ties, computer scientists tried to write a program thatwould translate 4nglish into Hussian and Hussian into 4nglish. /his is really thesamepro$lemofproperlyunderstandingthemeaningofhumanlanguage./hescientistsdecidedtotest theirprogram$yenteringan4nglishsentence. /heresulting Hussian sentence was then entered $ac% into the computer and the finalresultshould$etheoriginal4nglishsentence. Should, that is,ifthecomputercould translate correctly in $oth directions./he original sentence entered was@The s'irit is willing but the lesh is weakI do not ha*e a clue what the Hussian result was, $ut I do %now the final 4nglishresult.Our computer scientists were -uite surprised withThe 1odka is great but the meat is rotten5age 1.32 Exposure 7a!a8 200& E%ition 0*91*90&/his little e&periment showed the ma2or pro$lem with human languages. #umanlanguages li%e 4nglish are idiomatic. We use all these idioms and pro*er$s, andslangandspecial nuances that are meaninglessto the computers. #owcancomputers figure out human language, when humans are confused? /he $ottomline is that programming re-uires a restricted language. /his language can ha*ehuman type words, $ut the words selected, the sym$ols and punctuation used, allmust ha*e a *ery precise meaning. /he mannerinwhichtheprogram languagestructures itsstatements iscalledsynta&. "rogramlanguagesmust ha*e*eryprecise synta&.>ompilers first chec% to see if a program has correct synta&.Onlyafter the synta&chec%s out, isthe ne&t stepof translatinginto$inarycodeperformed.5 %rie/ 1istory o/ !rogram .anguages/hefirst successful programminglanguagefor the mathematics andscientificcommunity,;0/O3OL asits official programming language.16 followed, trying to $e a language for e*ery$ody."L8 attempted to $e $oth ane&cellent languagefor scienceandfor $usiness. /heresult wasane&tremelycum$ersome language that ne*er gained much popularity./hen there were a hostof many other shortli*ed languages.BA&('ABeginnerAllpurpose&ym$olic(nstructional'odeC wasdesignedfor$eginning collegestudents.BA&(' $ecamethefirstpopularprogram languagefor personal computers in the se*enties.BA&(' re-uired little memory, and it wasthe only language that could initially $e handled $y the first micro computers.In the late se*enties, early eighties,1ascaltoo% a strong hold in the educationalcommunity. 1ascalwas de*eloped $y .i%laus Wirth, specifically for the purposeof teaching proper computer science programming techni-ues./his language wasadopted for the )d*anced "lacement >omputer Science 4&amination in 89L: andstayed in that position until the 899L e&am.Intheearlyse*enties, the7.IOoperatingsystemwasde*elopedat the3ellla$oratories. /hisoperatingsystemwaswritteninse*erallanguagessomeofwhichwerecalled B'16 or2ustplain B.) later*ersionofthelanguagewascalled ', since it followed B. In the eighties, the ' language $ecame *ery popularas the language of choice for operating systems.Chapter 4 4ntro%uction to Computer Science 5age 1.33)s the demands for sophisticated computer uses grew, so did the demand for e*ermore sophisticated computer programming languages.) new era with a powerfulprogrammingtechni-uewas$orncalled 2bject2riented3rogrammingA001C.(ou are hardly in a position to appreciate the finer features of 001. Hight nowappreciate that a new language had to $e de*eloped to incorporate the power ofOO".32arne Stroustrup com$ined the popularity of the e&isting > language withthe demands for OO"and de*eloped >FF. >FFincludes all the pre*iouscapa$ilitiesof>, manyimpro*ementsontheearly>, andthenewfeaturesofo$2ect orientedprogramming.>FFactuallyissomewhat ofahy$ridlanguagesinceo$2ectorientedStyle"rogrammingispossi$le,$ut soistheolder>styleprogramming that todayBs modern programmers frown upon./here is something else that you need to understand a$out this program languagestuff.(ou can say that there is one le*el a$o*e the compiler, called the lin%er.Itdid not ta%e computer scientists long to figure out that the ma2ority of programsuse the same source code in each and e*ery program./his is the type of code usedwithinput andoutput, mathematicalcalculations, etc. It seemedsillyto%eepcreatingthis code o*er ando*eragain. Specialli$raryfilesof handycomputerroutines were created and already translated into special machine code files..owthesefilescannot $ee&ecuted$ythe>"7$ecausetheinstructionset isnotcomplete.Such files are %nown as o$2ect files. When modern programmers write a compiled program, li%e >FF, they write theirownpersonalsourcecodeandthecompilerchec%stheirsynta&toma%esuree*erything is written correctly./he first pass through the program is the compilepass. .ow a second pass lin%s the compiled code with any other li$rary file andcom$ines it into one nifty file that can $e used $y the computerEs >"7.Ba*a Comes on the Scene>FFwillcontinueto$ea*eryimportant programminglanguageforyearstocome. /he industrial strength features and the tremendous num$er of programswritten in >FF guarantee its sur*i*al.In the early .ineties Sun Microsystems wor%ed on a language called 0ak. /hemainfocusof thisnewlanguagewasto $eplatformindependent ando$2ectoriented."latform independent means that the language does not cause pro$lemsas programs are transported $etween different hardware and software platforms.Oa% was used internally $y Sun Microsystems for a$out four years and released tothepu$licin899,withthenewname>a:a. !a*awasa$igsuccesslargely$ecause the new language was perfectly suited for the Internet.7ni*ersities also adopted !a*a *ery rapidly. 3y the late .ineties o$2ectorientedprogramming was taught e*erywhere and the new language !a*a ga*e no choice5age 1.34 Exposure 7a!a8 200& E%ition 0*91*90&li%e >FF./his appealed to many college professors who did not li%e the fact that>FF allowed, older nonOO" programming./he >ollege 3oard adopted !a*a as the )" >omputer Science language to $e usedfor its e&amination starting with the NII+NII: schoolyear. )nd you ha*e 2uststarted a computer science course that will use !a*a as its programming language.1.10?etwor-ingWhen you grow up in a certain en*ironment, it can easily seem natural, as if theen*ironment was always the way you see it. /odayBs students thin% it is perfectlynormal that computers can use email, play *ideo games and surf the Internet. Itwas not always that simple. >omputers e*ol*ed and yes computers do seem toe*ol*e much faster than almost any other type of human creation.The Snea-er?et4arly personal computers were not networ%ed at all.4*ery computer was a standalone computer. Some computers were hoo%edup to printers andmany otherswere not.If you needed to print something, and you were not directly connectedto a printer, you stored your document on a floppy dis%ette, wal%ed to a computerwith an attached printer, and then printed the document. If a group of computerprogrammers wor%ed together on a pro2ect, they needed to get up fre-uently withstored information to share it with other mem$ers in the team.Hunning around tosharecomputerinformationisnow called the0neakerNet. Itmay not $e*erycle*er, $ut it does illustrate the en*ironment.!eer=to=!eer ?etwor-s>omputersdidnot wa%euponedayandhoo%eduptotheInternet./hefirstpractical networ%s for personal computers were peertopeer networ%s.) peertopeer networ% is a small group of computers with a common purpose all connectedChapter 4 4ntro%uction to Computer Science 5age 1.3toeachother./hissmallnetwor%allowedasingleprinterto$eused$yanycomputer onthenetwor%andcomputerscouldalsoshareinformation. /hesetypes of networ%s were fre-uently called 4ocal Area Networks or L).s.Initially,the networ%s were true 'eer-to-'eer networ%s. /his means that e*ery computeron the networ% was e-ual.)ll computers were personal computer wor% stations.Later, dedicatedcomputers wereused, calledser*ers. )ser*er isaspecialtycomputer that is connected to the L). for one or more purposes.Ser*ers can $eused for printing, logon authentications, permanent data storage andcommunication.Many$usinesseswouldha*emultipleser*erssetupinsuchamanner that some ser*ers e&ist for the purpose of $ac%ing up the primary ser*er.7sing$ac%upsystems, tapestorageor other $ac%upmeansinsuredcomputerrelia$ility in case of computer failure.The 8epartment "/ 8e/ense ?etwor-ing $o&eIt may come as a shoc% to you, $ut the Internet was not created so that teenagerscould play *ideo games and download music. /he Internet has its origins in the?>old War.?If you do not %now what the ?>old War? is as% your Social Studiesteacher, your parents or any old person o*er +I.6uring the >old War there was ama2orconcerna$out thecountry$eingparaly0ed$yadirect nuclearhitonthe"entagon. It usedto$ethat allmilitarycommunicationstra*eledthroughthe"entagon. Ifsomeenemyforcecould%noc%out the"entagon, therest ofthemilitary esta$lishment would $e lost.) means of communication had to $e createdthat was capa$le to %eep wor%ing regardless of damage created anywhere. /hiswas the $irth of the Internet./he Internet has no central location where all thecontrol computers are located. )ny part of the Internet can $e damaged and allinformation will then tra*el around the damaged area.The :odern InternetStudents often thin% that the Internet is free.Well that would $e lo*ely, $ut $illionsofdollarsarein*estedinnetwor%inge-uipmentthat needsto$epaidinsomefashion.>omputersallo*ertheworldarefirstconnectedtocomputerswithintheir own $usiness or school. .ormally, $usinesses and schools ha*e a series ofL).s that all connect into a large networ% called an Intranet.)n Intranet $eha*esli%e the Internet on a local $usiness le*el./his promotes security, speed and sa*escost..ow the moment a school, a $usiness, your home, wants to $e connected to theoutsideworldandgiant worldwidenetwor%%nownastheInternet, youha*eaccess to millions of lines of telecommunications./his will cost money and e*eryperson, e*eryschool. 4*ery$usinesswhowants thisaccess needsto useanInternet 0ervice 3rovider or IS".(ou pay a monthly fee to the IS" for the Internet5age 1.3# Exposure 7a!a8 200& E%ition 0*91*90&connection./he amount of money you pay depends on the amount of traffic thatflows through your connection and the speed of your Internet connection./odaymanycomputers useawirelessconnectionto hoo%upto somelocalnetwor%, that inturn hoo%s up to the Internet. Wireless connections arecon*enient, $ut there are some pro$lems.Signals are not always relia$le, 2ust li%ecell phones. (ou may $e stuc% in an area somewhere where the signal is wea%.5urthermore, there is the security issue.Information that tra*els wireless is mucheasier to pic% $y hac%ers than information that is channeled through ca$le.1.121ardware and So/tware>omputer science, li%e all technical fields, has a huge li$rary of technical terms andacronyms. 'olumes can $e filled with all %inds of technical *oca$ulary.#a*e nofearD you will not $e e&posed to *olumes, $ut at the end of this chapter you doneedsome e&posure to the more commonterms you will encounter inthecomputer world. (ouha*ealreadylearneda$out different types of memory,programminglanguagesandnetwor%ing. /hereareafewimportant computerterms that you need to understand.5or starters, it is important that you understandthe hardware andsoftwaredifference. /hese are the two $iggest di*isions inthe computer $usiness.#ardware in*ol*es all the computer components that can $e seen, felt, pic%ed upand dropped, li%e a monitor, a mouse, a 2ump dri*e.Software in*ol*es the set ofcomputer instructions that are coded on a dis%, a >6, or a hard dri*e.Computer 1ardware and !eriphera& 8e*ices/here are $ig, *isi$le hardware items that most students %now $ecause such itemsare difficult to miss. /his type of hardware includes the main computer $o&, themonitor,printer,andscanner. /hereareadditionalhardwareitemsthat arenot-uite as easy to detect.It helps to startatthemost essentialcomputercomponents. /hereisthe >"7A>entral "rocessing7nitC, whichcontrolsthecomputer operations. /he>"7together with the primary memory storage represents the actual computer.5re-uently, when people say to mo*e the >"7 to some des%, they mean the $ig$o& that contains the >"7 and computer memory.In reality it contains lots morethan 2ust a $unch of memory chips./here are also many peripheral de*ices.Chapter 4 4ntro%uction to Computer Science 5age 1.3&What does periphery mean?It means an imprecise $oundary.If the computers arelocated on the periphery of the classroom, then the computers are located againstthe walls of the classroom. >omputer hardware falls into two categories. /hereare internal peripheral de*ices and e&ternal peripheral de*ices.4&ternal peripheral de*ices were already mentioned./hese are hardware, locatedoutside the computer and connected with some interface, which is usually a ca$le,$ut itcanalso$ewireless./hefirste&ternalperipheralde*iceyouseeisthemonitor. In the old days a monitor was called a >H/ A>athode Hay /u$eC. /hiswas appropriate with the $ul%y monitors that loo%ed li%e old tele*isions. /odaymany monitors use L>6 ALi-uid >rystal 6isplayC screens.It is common now formonitors to $e86 HOM dri*e,digital camera memory dri*e, networ% interface card and *ideo card.Computer So/tware>omputer softwarepro*idesinstructionsto acomputer. /hemost importantaspect of this course is to learn how to gi*e correct and logical instructions to acomputer with the help of a programming language.Softwarefallsintotwocategories. /hereissystemsoftwareandapplicationsoftware. 7sually, students entering high school are already familiar withapplications software. )pplications software runs an application on a computer./he whole reason why acomputere&istsisso that itcanassistpeopleinsometypeofapplication.5orcenturies,accounting%ept large,complicatedspreadsheetsof$usinessnum$ers..ow these same num$ers are entered on an electronic spreadsheet. (ou will note&perience the horror of finding some mista%es on the early pages of a thirty page,typed, research paper. /his type of mista%e necessitates retyping the ma2ority ofthe pages. /oday, this is a simple matter of inserting the corrections on a wordprocessorprogram. Spreadsheetsandwordprocessorswerethe firstsoftwareapplications. >urrently, there are thousands of other applications to assist peoplein e*ery possi$le area from completing ta& returns to playing *ideo games.Systemsoftwarein*ol*estheinstructionsthat thecomputerre-uirestooperateproperly.) common term is OS Aoperating systemC./he ma2or operating systemsare Windows O", 7.IO and M)> OS. It is important that you understand the5age 1.3* Exposure 7a!a8 200& E%ition 0*91*90&operation of your operating system. With OS you can store, mo*e and organi0edata.(ou caninstall new e&ternalde*ices li%eprinters andscanners. (oucanpersonali0e your computer with a des%top appearance and color selections. (oucan install additional applications and computer protection against losing data and*iruses.1.14Summary/hishas$eenanintroductoryhodgepodgechapter. It isaw%wardto 2umpstraight into computer science without any type of introduction.Students arri*e ata firstcomputer sciencecourse with a wide*arietyof technology $ac%grounds.Somestudents%nowalittle%ey$oardingandInternet accessalongwith$asicword processing s%ills taught in earlier grades.Other students come to computersciencewithasophisticateddegreeof%nowledgethat canincludeathoroughunderstandingofoperatingsystemsandfre-uently%nowledgeofoneor moreprogram languages as well./he secret of computer information storage and calculation is the $inary system.Information is stored in a computer with com$inations of $aseN ones and 2eroes.Indi*idual $inary digits Abits) store a one or a 0ero.) one means true and a 0eromeans false.) set of eight $its forms one b,te.) $yte can store one character in memory with A&'((, which allows 256 differentcharacters./he newer, international -nicode stores one character in two $ytes fora total of 655$6 different characters..either this chapter nor this $oo% e&plainedanydetailsa$out the operatingsystem.Operating systems change fre-uently, or at least operating system *ersionschangetoanewandimpro*edmodela$out e*erytwoorthreeyears.) solid%nowledgeof your computerBsoperatingsystemis*ital. Writingacomputerprogram re-uires %nowledge of editing te&t, sa*ing and loading files and mo*ingaround the hard dri*eBs directory system efficiently.If your $asiccomputer %nowledgeiswea%, ma%esureto pic%upadditionalinformation from your teacher, li$rary or $oo%store. /echnology is e*ol*ing andstudents arri*e in computer science classes with increased sophistication. In thiscourse no prior %nowledge whatsoe*er a$out anyprogramminglanguage orprogramminglogicisassumed. #owe*er, afundamental %nowledgeof $asiccomputer operations is essential.Sun Microsystems created !a*a to $e a programming language that is porta$le on manycomputer platforms, a socalled 'latorm-inde'endent language./hey also wanted thelanguage to $e compati$le with we$ page de*elopment.Chapter 4 4ntro%uction to Computer Science 5age 1.3.4arly computers were standalone wor% stations./he first networ%ed computers useda ?peertopeer? networ%. /his was followed $y L).s ALocal )rea .etwor%sC thatconnecteddedicatedspecialtyser*erswithcomputersandprintersfor acommonpurpose. /he 6epartment of 6efense de*eloped the Internet as a means to pro*idecommunication at war time.Indi*iduals, schools and $usinesses can set up a L). at their pri*ate location withoutpaying a fee $eyond the cost of the necessary hardware and software.>onnection tothe Internet re-uires an IS" AInternet Ser*ice "ro*iderC and a monthly connection fee.Many computers today, especially laptop computers, ha*e wireless networ%connections.Such connections are con*enient, $ut they are not as relia$le and there isalso a greater security ris%.>omputers use hardware and software. #ardware peripheral de*ices are the *isi$lecomputer components. /herearee&ternal peripheral de*ices, suchas monitors,%ey$oards, printers and scanners. /here are also internal peripheral de*ices li%e dis%dri*es, >6 HOM dri*es, networ% interface cards and *ideo cards.Software fallsintotwo categories of applicationsoftware andoperatingsystemsoftware.)pplication software includes the common applications of word processingand spreadsheets, $ut also ta& return software and *ideo games. Operating systemsoftware runs the computer and allows the user to personali0e the computer to his orher needs and organi0e data.5age 1.40 Exposure 7a!a8 200& E%ition 0*91*90&