DOC PREVIEW
UT Arlington CSE 3302 - History of Programming Languages

This preview shows page 1-2-3-20-21-22-41-42-43 out of 43 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 43 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

CSE 3302 Programming LanguagesLanguages you used or heard aboutCan anybody sing this song?CPrologAssembly?Slide 8WhitespaceCowPiet (@!@#$%!^!)If you are interestedThousands out thereThe most popular PLs?HistoryThe First ProgrammerSlide 17The First ComputersSlide 19Slide 20The 1950s: The First Programming LanguagesFORTRANSlide 23Major languages following FORTRANCOBOLSlide 26Algol60LISPAPLSummary of 1950sThe 1960s: An Explosion in Programming LanguagesPL/ISimula67BasicThe 1970s: Simplicity, Abstraction, StudyThe 80s: New Directions and OOAdaSmalltalkC++Other Paradigms1990’s: Internet, ScriptingJavaWhat’s next?CSE 3302 Programming LanguagesChengkai LiSpring 2008History of Programming LanguagesLecture 2 - History, Spring 2008 1CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008Languages you used or heard aboutLecture 2 - History, Spring 2008 2CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008CC++C#JavaPythonPerlRubyHaskellFORTRANBASICJavaScriptPHPLISPGroovyFlexSQLShellXMLSGMLAssemblyLuaColdfusionDelphiForthJSPJ2MEAdaCOBOLRPGPostScriptPascalAPLPL/IVisual BasicLOGOMLPrologSmalltalkCan anybody sing this song?•99 Bottles of Beer99 bottles of beer on the wall, 99 bottles of beer.Take one down and pass it around, 98 bottles of beer on the wall.98 bottles of beer on the wall, 98 bottles of beer.Take one down and pass it around, 97 bottles of beer on the wall.…1 bottle of beer on the wall, 1 bottle of beer.Take one down and pass it around, no more bottles of beer on the wall.No more bottles of beer on the wall, no more bottles of beer. Go to the store and buy some more, 99 bottles of beer on the wall.Lecture 2 - History, Spring 2008 3CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008Cstatic void fill_buffer(char *buf, int b) { char line[BUFFERSIZE/2]; if (b>0) { sprintf(buf, "%d bottle%s of beer on the wall, %d bottle%s of beer.\n" \ "Take one down and pass it around, ", b, PLURALS(b), b, PLURALS(b)); if (b==1) strcat(buf, "no more bottles of beer on the wall.\n"); else { sprintf(line, "%d bottle%s of beer on the wall.\n", b-1, PLURALS(b-1)); strcat(buf, line); } } else { sprintf(buf, "No more bottles of beer on the wall, no more bottles of beer.\n" \ "Go to the store and buy some more, 99 bottles of beer on the wall.\n"); }….Lecture 2 - History, Spring 2008 4CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008Prologreport_bottles(0) :- write('no more bottles of beer'), !.report_bottles(X) :- write(X), write(' bottle'), (X = 1 -> true ; write('s')), write(' of beer').report_wall(0, FirstLine) :- (FirstLine = true -> write('No ') ; write('no ')), report_bottles('more'), write(' on the wall'), !.report_wall(X, _) :- report_bottles(X), write(' on the wall').…Lecture 2 - History, Spring 2008 5CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008Assembly inc eax ; get the original value push eax ; convert it to string lea eax, [ebp - 04h] push eax ; string will be stored here call _integer_to_string lea eax, [ebp - 04h] push eax call _show_line ; 'xx' push _line_1_1 call _show_line ; ' bottles of beer on the wall, ' lea eax, [ebp - 04h] push eax …Lecture 2 - History, Spring 2008 6CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008?select CASE (a.aa * 10 + b.bb) WHEN 0 THEN 'No more bottle of beer on the wall, no more bottles of beer. ' + 'Go to the store and buy some more, 99 bottles of beer on the wall.' WHEN 1 THEN '1 bottle of beer on the wall, 1 bottle of beer. ' + 'Take one down and pass it around, no more bottles of beer on the wall.' WHEN 2 THEN '2 bottles of beer on the wall, 2 bottles of beer. ' + 'Take one down and pass it around, 1 bottle of beer on the wall.' ELSE cast((a.aa * 10 + b.bb) as varchar(2)) + ' bottles of beer on the wall, ' + cast((a.aa * 10 + b.bb) as varchar(2)) + ' bottles of beer. ' + 'Take one down and pass it around, ' + cast((a.aa * 10 + b.bb)-1 as varchar(2)) + ' bottles of beer on the wall.' ENDfrom (select 0 as aa union select 1 union select 2 union select 3 union select 4 union select 5 union select 6 union select 7 union select 8 union select 9) across join (select 0 as bb union select 1 union select 2 union select 3 union select 4 union select 5 union select 6 union select 7 union select 8 union select 9) border by a.aa desc, b.bb descLecture 2 - History, Spring 2008 7CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008?bottles = [98:-1:3]; % bottles 98 to 3 (99, 2 & 1 are treated as special case)lines = 3; % need the number of bottles at the beginning of 3 linesnum_array = ones(lines,1) * bottles; % bottles is a (1x96) arrayformat_plural1 = '%d bottles of beer on the wall,\n%d bottles of beer,\n';format_plural2 = 'Take one down, pass it around,\n%d bottles of beer on the wall.\n\n';format_sing1 = '%d bottle of beer on the wall,\n%d bottle of beer,\n';format_sing2 = 'Take one down, pass it around,\n%d bottle of beer on the wall.\n\n';format_none2 = 'Take it down, pass it around,\nNo bottles of beer on the wall.\n';fprintf([format_plural1 format_plural2], 99,99,num_array,2)fprintf([format_plural1 format_sing2], 2,2,1)fprintf([format_sing1 format_none2], 1,1)Lecture 2 - History, Spring 2008 8CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008WhitespaceWhitespace version of 99 bottles of beer (Bottles.ws) 2003-04-01See http://compsoc.dur.ac.uk/whitespace/ for details+interpreterExample by Andrew Kemp <[email protected]> (*All* space/tab/linefeed characters are significant!) Lecture 2 - History, Spring 2008 9CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008CowmoOMoOMoOMoOMoOmoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMMMmoOMMMMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMMMmoOMMMommMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMMMmoOMMMMoOMoOMMMmoOMMMMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMoOMMMmoOMMMMoOMMMmOomOomOomOomOomOoMMMMoOmoOmoOmoOmoOmoOmoOMMMmoOMMMMoOMoOMMMmoOMMMMoOMMMmoOMMMMoOMMMmoOMMMMoOMoOMMMmoOMMMMoOMMMmoOMMMMoOMoOMMMmoOMMMMoOMMMmoOMMMMoOMoOMMMmoOMMMMoOLecture 2 - History, Spring 2008 10CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,


View Full Document

UT Arlington CSE 3302 - History of Programming Languages

Documents in this Course
Smalltalk

Smalltalk

11 pages

Syntax

Syntax

5 pages

Syntax

Syntax

5 pages

JAVA

JAVA

57 pages

Semantics

Semantics

41 pages

Control

Control

74 pages

Load more
Download History of Programming Languages
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view History of Programming Languages and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view History of Programming Languages 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?