CS 424

5.0(1)
studied byStudied by 48 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/112

flashcard set

Earn XP

Description and Tags

Final Exam Explained

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

113 Terms

1
New cards

Reasons for studying concepts of programming languages (5 Reasons)

Better Understanding, Increase Computational idea capacity, Ability to learn languages, Compare Two languages for better use in situation, significance of implementation

2
New cards

Readability

How easy a programming language is to read, ie syntax

3
New cards

Writability

Measure of ease to write solutions

4
New cards

Reliability

Degree to which programs perform without errors

5
New cards

Cost

Time for development, time, or resources used

6
New cards

Simplicity

How very easily understandable and basic a language is. Impacts writability and readability

7
New cards

Orthogonality

These symbols mean exactly what they mean and there is a lack of extra conditions. Real life example is changing the TV channel which doesn’t change the volume or anything else

8
New cards

Non-Orthogonality

Allows for another thing to happen when writing the code. Real life example is something like a helicopter changing direction as speed increases

9
New cards

Von Neumann

The architecture that is most commonly used

10
New cards

Imperative

data oriented programming language. Think the language C.

11
New cards

Object Oriented Programming

Object focused languages like C++

12
New cards

Interpreted

Doesn’t turn into binary to execute or just not compiled. Example is Javascript

13
New cards

Hybrid

High level to intermediate language which combines compiled and interpreted. Example is Java or C#

14
New cards

Compiled

Language will go through a compiler before executing. Example is C++

15
New cards

Static

Compile time legaility checking

16
New cards

Dynamic

Run time legality checking

17
New cards

Compiled VS Interpreted VS Hybrid

Compiled - Faster to execute, slower to write
Interpreted - Slower to execute, Faster to write
Hybrid - Very average between the other two

18
New cards

Syntax

Form that dictates how a language is written

19
New cards

Semantics

Meanings of what has been written from the language

20
New cards

Lexemes

Characters

21
New cards

Tokens

Sets of characters

22
New cards

Lexical Analysis

Valid characters being used check

23
New cards

From Lexical Analysis to Tokens

Symbols that the language can understand

24
New cards

Tokens to Syntactic Analysis

Valid statements being written

25
New cards

From Syntactic analysis to Compute

Has to check for valid data to compute the syntax

26
New cards

BNF Stands for

Backus Naur Form and is the Natural notation for describing syntax

27
New cards

Parse Tree

Used based on the BNF grammar rules.
If given someyhing like assign, expression, term, fact, id. order would as written. ID is usually created using two “ marks

28
New cards

Precedence

PEMDAS in Math or a vertical movement

29
New cards

Associativity

Which to do based off of rules on the same horizontal level. Such as Multiply or Divide on the same level

30
New cards

Ambiguity

More than 1 parse tree can be created from the expression

31
New cards

Attribute

Left Side

32
New cards

Predicate

Right side of grammar

33
New cards

Names

String of characters used to identify an entity in a program

34
New cards

Reserved Word

A special word that cannot be used as a name

35
New cards

Address of Variable

memory location

36
New cards

Type of variable

classification

37
New cards

Binding of Variable

value association

38
New cards

Scope of variable

range of statements where variable is visible

39
New cards

Lifetime of variable

time bound to a memory location

40
New cards

Name of a variable

in code identifier

41
New cards

Data type

types that have predefined logical operations

42
New cards

Pointer

refers to an address within memory

43
New cards

References

refers to an object or value within memory

44
New cards

Gabrage Collection

frees up no longer used memory

45
New cards

Dangling pointers

pointers that point to a memory location that is not valid

46
New cards

Side Effects

function alters memory locations outside of the scope

47
New cards

Widening

Upcast like int → Float

48
New cards

Narrowing

Downcast like double → float

49
New cards

Coercion

process of converting one type of data type to another

50
New cards

Imperative Programs

2 forms of control statements
Selecting among alternatives = if else
Repeating Selected Statements = for & while loops

51
New cards

One Way

Selects between 2 actions based on a single condition. If statement

52
New cards

Two way statement

If- Else

53
New cards

Multi-way statement

Switch, n-many if, case, elif

54
New cards

Examples

Iterative Statement - For Loop

Condition Controlled Loops - While

Count Controlled Loops = For Loop

55
New cards

Iteration based on data structure

iterator similar to a python for loop

56
New cards

Communicating Sequential Processes

Interactions between concurrent processes. IE multithreading

57
New cards

Guarded Commands

Basis for communicating sequential processes for a non-deterministic program

58
New cards

Fundamentals of Subprograms

Only load as they come into memory

One single entry

Control retunred to caller at termination

59
New cards

Subprogram

Self contained part of code that can be called anywhere within the program

60
New cards

Call

explicit request for execution

61
New cards

Active

subprogram is in execution

62
New cards

Header

type and parameter profile

63
New cards

Body

executable logic

64
New cards

Formal Parameters

Defined in header

65
New cards

Actual Parameters

values passing in

66
New cards

Positional Parameters

Refers the actual to the formal parameters

67
New cards

Keyword Paraemeters

name of formal used to map to actual parameters. Think of an alias

68
New cards

Default Parameters

default values passed if nothing is sent in

69
New cards

Design Issues for Subprograms

1) Can they be overloaded?

2) What parameter passing methods are used?

3) Static or dynamic local variables?

70
New cards

Activation Record

organization of variables in addition to implementation of lifetime and scope of the variables in a table like set up

71
New cards

Run Time Stack

All stack frames at the current postion

72
New cards

Environment Pointer

Holds beginning of current activation recordD

73
New cards

Dynamic Link

link to location where called

74
New cards

Static Chain

start of each activation record

75
New cards

Static Depth

Integer that hold the value of each scope level

76
New cards

Nesting Depth

Difference of current scope depth and the depth of the variable access

77
New cards

Offset

Beginning of Activation Record to beginning of storage point

78
New cards

Deep Access

references to non local variables through dynamic links

79
New cards

Shallow Access

alternative way of implementing dynamic scope

80
New cards

Abstraction

Combining of logical operations

81
New cards

Process Abstractions

Hiding details of thread execution

82
New cards

Abstract Data Type

Data type’s behavior is from the user

83
New cards

Encapsulation

building data and methods into a single unit

84
New cards

Information Hiding

keeping information from the users

85
New cards

Required Features of OOP Languages and Definitions

Objects = Procedures and Data

instantiation = Creating an object from a class

Inheritance = making new classes by changing existing ones

Polymorphism = use of one symbol to represent many types

86
New cards

Single Inheritance

derived class rom a single base class

87
New cards

Multiple Inheritance

class derives from multiple parent classes

88
New cards

Generalization

subclass into a superclass

89
New cards

Specialization

Creates more specific classes from higher

90
New cards

Parent/Child

Class relationship where child inherits from parent class

91
New cards

Pure Object Oriented Language

Needs:
Small Talk
Everything as an object
Has encapsulation

92
New cards

Exception Handling and Event Driven similarities

Involved reading to specific occurrences within a system

Triggered by something happening

Decoupling Mechanisms

93
New cards

Design Issues for Exception Handling

Identify and categorize exceptions

Checked or unchecked exceptions

Granularity of exceptions

Creating without harming code readability

94
New cards

Functional Programming Languages

LISP, Haskell

Pure Functions to build and edit software

95
New cards

Math Functions

all functions are seen as deterministic math functions

96
New cards

Fundamentals of Functional Programming Languages

uses pure functions

recursions

cant modify variables

97
New cards

Basics of primitives

built in functions that operate on numbers, symbols, and lists

98
New cards

Basics of lists,numbers, and symbols

All fundamental data types

99
New cards

Doman and Range

X-Axis

Y-Axis

100
New cards

Referential Transparency

replaces properties without changing program’s behavior