Created By : Robert W. Sebesta
Lecturer : Mr. Tri Djoko Wahjono, Ir. M.Sc
Answered by : Shirley Halim Ng
NIM : 1601233805
Class : 02PCT
Review questions
3. What does Plankalkül mean?
=> Plankalkül means program calculus.
18. What two professional organizations together designed ALGOL 60?
=> The two professional organizations are European ALGOL Bulletin and Communications of the ACM.
22. On what language was COBOL based?
=> COBOL based on ALGOL 60 language.
23. In what year did the COBOL design process begin?
=> It began in 1959.
28. PL/I was designed to replace what two languages?
=> PL/I was designed to replace FORTRAN and COBOL languages.
33. What language introduced the case statement?
=> A Language that introduced the case statement is ALGOL-W.
36. Why is Prolog called a nonprocedural language?
=> As we know, the name Prolog is from programming logic. Programming in logic programming languages is nonprocedural. Programs in such languages do not state exactly how a result is to be computed but rather describe the necessary form and/or characteristics of the result.
46. What is primary application for Objective-C?
=> The primary application for Objective-C is Objective-C 2.0.
47. What language designer worked on both C and Go?
=> The language designer that worked on both C and Go is Ken Thompson.
49. What was the first application for Java?
=> The first application for Java was Sun Microsystems.
53. What two languages was the original version of Perl meant to replace?
=> Perl language was originally a combination of sh and awk.
54. For what application area is JavaScript most widely used?
=> It’s most widely used in Web browser.
57. What data types does Java support?
=> Java supports int, float, string, double, char, etc.
64. What is primary platform on which C# is used?
=> The primary platform on which C# is used is .NET.
65. What is the input to an XSLT processor?
=> The input to an XSLT processor is an XML data document and an XSLT document.
66. What is the output to an XSLT processor?
=> The output to an XSLT processor is the transformation information.
69. Where is .jsp files executed?
=> It is executed on a Web server system.
Problem Set
4. As a research project, compare the features of C with those of the BASIC.
=> The syntax and operation is very similar, but visual basic isn't as powerful. Think of it as a watered down, easier version of c. With C, you can create anything from a simple calculator application to a full blown operating system. Visual basic can't make anything as extensive as an operating system, but it is much faster to code in visual basic when you want to make form based programs, or applications.
Features in C :
Low Level Features :
1. C Programming provides low level features that are generally provided by the Lower level languages. C is Closely Related to Lower level Language such as “Assembly Language“.
2. It is easier to write assembly language codes in C programming.
Portability :
1. C Programs are portable i.e they can be run on any Compiler with Little or no Modification
2. Compiler and Preprocessor make it Possible for C Program to run it on Different PC
Powerfull :
1. Provides Wide verity of ‘Data Types‘
2. Provides Wide verity of ‘Functions’
3. Provides useful Control & Loop Control Statements
Bit Manipulation :
1. C Programs can be manipulated using bits. We can perform different operations at bit level. We can manage memry representation at bit level. [Eg. We can use Structure to manage Memory at Bit Level]
2. It provides wide verity of bit manipulation Operators. We have bitwise operators to manage Data at bit level.
High Level Features :
1. It is more User friendly as compare to Previous languages. Previous languages such as BCPL,Pascal and other programming languages never provide such great features to manage data.
2. Previous languages have there pros and cons but C Programming collected all useful features of previous languages thus C become more effective language.
Modular Programming :
1. Modular programming is a software design technique that increases the extent to which software is composed of separate parts, calledmodules
2. C Program Consist of Different Modules that are integrated together to form complete program
Efficient Use of Pointers :
1. Pointers has direct access to memory.
2. C Supports efficient use of pointer .
More Efficient
Features in BASIC :
Arrays
Discusses making your code more compact and powerful by declaring and using arrays, which hold multiple related values.
Collection Initializers
Describes collection initializers, which enable you to create a collection and populate it with an initial set of values.
Constants and Enumerations
Discusses storing unchanging values for repeated use, including sets of related constant values.
Control Flow
Shows how to regulate the flow of your program's execution.
Data Types
Describes what kinds of data a programming element can hold and how that data is stored.
Declared Elements
Covers programming elements you can declare, their names and characteristics, and how the compiler resolves references to them.
Delegates
Provides an introduction to delegates and how they are used in Visual Basic.
Early and Late Binding (Visual Basic)
Describes binding, which is performed by the compiler when an object is assigned to an object variable, and the differences between early-bound and late-bound objects.
Error Types (Visual Basic)
Provides an overview of syntax errors, run-time errors, and logic errors.
Events
Shows how to declare and use events.
Interfaces
Describes what interfaces are and how you can use them in your applications.
LINQ
Provides links to topics that introduce Language-Integrated Query (LINQ) features and programming.
Objects and Classes
Provides an overview of objects and classes, how they are used, their relationships to each other, and the properties, methods, and events they expose.
Operators and Expressions
Describes the code elements that manipulate value-holding elements, how to use them efficiently, and how to combine them to yield new values.
Procedures
Describes Sub, Function, Property, and Operator procedures, as well as advanced topics such as recursive and overloaded procedures.
Statements
Describes declaration and executable statements.
Strings
Provides links to topics that describe the basic concepts about using strings in Visual Basic.
Variables
Introduces variables and describes how to use them in Visual Basic.
XML
Provides links to topics that describe how to use XML in Visual Basic.
6. Make an educated guess as to the most common syntax error in C programs.
=> The most common syntax error in C programs are missing the (;) semicolon at the end of statement, missing “&” when using scanf, send the wrong paramater when using function, missing specific library when using specific function, missing () or missing {}, etc.
10. Outline the major developments in ALGOL 60.
=> - The concept of block structure was introduced. This allowed the programmer to localize parts of programs by introducing new data environments, or scopes.
- Two different means of passing parameters to subprograms were allowed: pass by value and pass by name.
- Procedures were allowed to be recursive. The ALGOL 58 description was unclear on this issue. Note that although this recursion was new for the imperative languages, LISP had already provided recursive functions in 1959.
- Stack-dynamic arrays were allowed. A stack-dynamic array is one for which the subscript range or ranges are specified by variables, so that the size of the array is set at the time storage is allocated to the array, which happens when the declaration is reached during execution.
13. What is the primary reason why C became more widely used than Fortran?
=> The reasons why C became more widely use than Fortran:
- Efficient compilers are universally available for all the main architechtures in use, and a good public compiler also exists (gcc). C compilers often come free with machines, while Fortran 90 compilers must be purchased, and often expensive.
- C is very broad in scope, and is more powerful of Fortran 90 in some areas, such as pointers, and manipulations of strings of characters.
- Acquired coding experience can be directly used outside the scientific world : C is very common in commercial world.
15. Are there any nonprocedural programming language other than prolog?
=> Yes, there are Fortran, C++, COBOL, Algol.
16. What is your opinion of the argument that languages that are too complex are too dangerous to use, and we should therefore keep all languages small and simple?
=> Languages are too complex are too dangerous to use because of its meaning itself. Ambiguous languages can cause trouble and misunderstanding among people. So, we must keep it small and simple to avoid ambiguation and misunderstanding.
24. Why, in your opinion, do new scripting languages appear more frequently than new compiled languages?
=>New appear languages appear more frequently than new compiled languages because they are often smaller and simpler and focused on more narrow applications, which means their library need not to be nearly as large.
25. Give a brief general description of the Java servlet!
=> A servlet is a Java programming language class used to extend the capabilities of a server. Although servlets can respond to any types of requests, they are commonly used to extend the applications hosted by web servers, so they can be thought of as Java Applets that run on servers instead of in web browsers. These kinds of servlets are the Java counterpart to non-Java dynamic Web content technologies such as PHP and ASP.NET.