Ch 1

0.0(0)
studied byStudied by 1 person
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/115

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 6:22 PM on 10/16/23
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai

No analytics yet

Send a link to your students to track their progress

116 Terms

1
New cards

What were the first digital computers used for?

Scientific applications.

2
New cards

What were the simple data structures used in early computers?

Arrays and matrices.

3
New cards

What type of arithmetic was commonly performed on early computers?

Floating-point arithmetic.

4
New cards

Which was the first high-level programming language developed for scientific applications?

Fortran.

5
New cards

Besides Fortran, which other programming language was used for scientific purposes?

ALGOL 60 and its descendants.

6
New cards

Is Fortran still used today for scientific applications?

Yes, for some highly efficient scientific apps from the 1950s and 1960s.

7
New cards

When did business computer use start?

1950s

8
New cards

What is COBOL?

The first successful high-level language for business

9
New cards

What are the main focuses of business languages?

Report generation, precise decimal data handling, and decimal arithmetic operations

10
New cards

What type of computations does AI use?

Symbolic computations, not numeric ones.

11
New cards

What is manipulated in AI?

Symbols (names, not numbers).

12
New cards

What data structure is preferred for symbolic computation?

Linked lists.

13
New cards

What is required for AI programming?

Flexibility, including code creation during execution.

14
New cards

What was the first widely used AI programming language?

Lisp (1959).

15
New cards

What alternative approach was introduced by Prolog?

An alternative approach to AI programming.

16
New cards

What type of languages are used in some recent AI apps?

Systems languages like C.

17
New cards

Which programming languages are covered in later chapters?

Scheme and Prolog.

18
New cards

What are markup languages?

Languages like HTML used in the World Wide Web.

19
New cards

What are programming languages?

Languages like Java used in the World Wide Web.

20
New cards

What is dynamic content?

Content that involves embedded programming in the World Wide Web.

21
New cards

What are scripting languages?

Languages like JavaScript and PHP commonly used for dynamic content in the World Wide Web.

22
New cards

What makes developing evaluation criteria controversial?

Varying opinions on language characteristics.

23
New cards

What are some key characteristics that affect evaluation criteria?

Readability, language simplicity, feature multiplicity, operator overloading.

24
New cards

Why is readability a crucial criterion?

Shift from machine-oriented to human-oriented design.

25
New cards

What can make programs convoluted in terms of readability?

Using an inappropriate language for the problem domain.

26
New cards

Why is language simplicity important for readability?

Large number of constructs can hinder learning and lead to subset usage.

27
New cards

What can complicate readability in a language?

Feature multiplicity and operator overloading.

28
New cards

What can reduce program readability in extreme cases?

Assembly language and languages with inadequate control and data-structuring constructs.

29
New cards

What does orthogonality mean in programming languages?

Using a small set of constructs to create control and data structures, with every combination being legal and meaningful.

30
New cards

What are orthogonal language features?

Context-independent and symmetrical.

31
New cards

What are the consequences of lack of orthogonality?

Exceptions, restricting a language's writability and learnability.

32
New cards

How is orthogonality related to simplicity?

It makes languages easier to learn, read, and understand.

33
New cards

Can you provide examples of non-orthogonality and context dependence in C programming?

N/A

34
New cards

What can too much orthogonality lead to?

Complexity, as seen in ALGOL 68.

35
New cards

What results in simplicity in programming languages?

A combination of a small number of primitive constructs and limited orthogonality.

36
New cards

What challenges do functional languages like Lisp face?

Efficiency, despite offering simplicity and orthogonality.

37
New cards

How does adequate facilities for defining data types and structures aid readability?

By making code more understandable and clear.

38
New cards

What is the impact of special words on program appearance and readability?

Special words affect program appearance and readability.

39
New cards

How does compound statement formation vary in different languages?

Compound statement formation varies in languages.

40
New cards

Why is distinct closing syntax for statement groups beneficial for readability?

Distinct closing syntax improves readability.

41
New cards

What can happen if special words are used as variable names?

Using special words as variable names can lead to confusion.

42
New cards

How can statements be designed for clear appearance in line with their purpose?

Statements can be designed for clear appearance to improve readability.

43
New cards

Why is consistency in semantics derived from syntax important for readability?

Consistency in semantics derived from syntax is essential for readability.

44
New cards

What can hinder readability in programming languages?

Context-dependent meanings can hinder readability.

45
New cards

What criticism do shell commands in UNIX often face?

Shell commands in UNIX are often criticized for not suggesting their function.

46
New cards

What should a language's appearance offer clues about?

A language's appearance should offer clues about its functionality.

47
New cards

What does writability measure in a programming language?

Writability measures how easily a language can create programs.

48
New cards

How do characteristics affecting readability often influence writability?

Characteristics affecting readability often influence writability.

49
New cards

In what context should writability be evaluated?

Writability must be evaluated within the context of the problem domain.

50
New cards

How does the domain in which a language excels impact its writability?

Different languages excel in different domains, impacting their relative writability.

51
New cards

What enhances writability in a programming language?

A smaller number of primitive constructs and orthogonality enhance writability.

52
New cards

What can too much orthogonality in a language lead to?

Too much orthogonality can lead to undetected errors and code absurdities.

53
New cards

What does expressivity in a language involve?

Expressivity involves powerful operators or convenient ways to specify computations.

54
New cards

What are some convenient features that improve writability?

Convenient features like short-circuit evaluation or the for statement improve writability.

55
New cards

What is a reliable program?

A program that performs to its specifications under all conditions.

56
New cards

Why is type checking crucial for language reliability?

It helps eliminate type errors and ensures program correctness.

57
New cards

What is the benefit of early error detection during compile time?

It reduces repair costs.

58
New cards

How does Java ensure type safety?

It includes extensive compile-time type checking to eliminate type errors at runtime.

59
New cards

What was the consequence of not type checking in original C?

Countless program errors occurred.

60
New cards

What is the role of exception handling in program reliability?

It allows programs to intercept and correct runtime errors.

61
New cards

Why is aliasing considered dangerous?

It can lead to unexpected behavior and errors.

62
New cards

Do many languages allow aliasing?

Yes, but some languages can restrict it for increased reliability.

63
New cards

How does writability impact reliability?

Unnatural programming approaches are less likely to be correct.

64
New cards

How does readability affect reliability?

Difficult-to-read programs are harder to write and maintain, reducing reliability.

65
New cards

What are the maintenance costs for large software systems?

2 to 4 times development costs.

66
New cards

What are the most important cost factors?

Program development, maintenance, and reliability.

67
New cards

What factors do program development, maintenance, and reliability depend on?

Writability and readability.

68
New cards

What are some other evaluation criteria for language design?

Portability, generality, and well-definedness.

69
New cards

What are the challenges in defining and measuring readability, writability, and reliability?

They are difficult to precisely define and measure.

70
New cards

What insights do readability, writability, and reliability offer into language design?

Valuable insights.

71
New cards

What can lead to conflicts in language design?

Different stakeholders prioritizing criteria differently.

72
New cards

What factors influence the total cost of a programming language?

Cost of training programmers, cost of writing programs, cost of compiling programs, cost of executing programs, cost of language implementation system, cost of poor reliability, cost of program maintenance.

73
New cards

How does simplicity, orthogonality, and programmer experience affect training costs?

They can impact the cost of training programmers.

74
New cards

What is the relationship between writability and the language's suitability for the application?

Writability depends on the language's suitability for the application.

75
New cards

How can high compiler costs impede language adoption?

High compiler costs can impede language adoption.

76
New cards

What impact does design have on execution speed?

Design can impact execution speed.

77
New cards

How can runtime type checks hinder efficiency?

Runtime type checks can hinder efficiency.

78
New cards

What limits language adoption in terms of language implementation system?

Expensive or hardware-dependent systems limit language adoption.

79
New cards

What are the costs associated with poor reliability?

Critical system failures and failures in noncritical systems can have high costs.

80
New cards

How does readability influence program maintenance costs?

Readability influences maintenance costs.

81
New cards

What is the von Neumann computer architecture?

Architecture that stores data and programs in the same memory.

82
New cards

What are imperative languages closely tied to?

von Neumann architecture.

83
New cards

What are the features of imperative languages?

Variables, assignment statements, and iterative repetition.

84
New cards

Why is iteration efficient on von Neumann computers?

Due to the fetch-execute cycle.

85
New cards

What is the fetch-execute cycle?

Instructions are fetched from memory and executed in the CPU.

86
New cards

What is the primary computation method in functional languages?

Function application.

87
New cards

What do functional languages eliminate?

Variables, assignment statements, and iteration.

88
New cards

Why are functional languages unlikely to replace imperative languages?

Non-von Neumann computers don't support efficient execution.

89
New cards

What is one argument for the dominance of imperative languages?

They feel more natural to users.

90
New cards

What are the four groups of programming languages?

Imperative, functional, logic, and object-oriented.

91
New cards

How do object-oriented programming languages evolve?

They grow out of imperative languages and require minimal extensions.

92
New cards

What are scripting languages?

They are essentially imperative languages with an emphasis on interpretation.

93
New cards

How do logic programming languages differ from imperative and functional languages?

They are rule-based and have significant differences.

94
New cards

What are markup/programming hybrid languages?

They are languages like HTML that incorporate programming capabilities.

95
New cards

What is the purpose of markup/programming hybrid languages?

To extend markup languages with programming capabilities.

96
New cards

What are the components of a computer?

Internal memory and a processor.

97
New cards

What is the role of the processor in a computer?

To execute machine instructions.

98
New cards

What is machine language?

The only language that hardware computers inherently understand.

99
New cards

How would you describe machine language?

Usually low-level and complex.

100
New cards

What do operating systems provide?

Higher-level primitives and system resource management.