language test 2 Flashcards

1
Q

let, let*, letrec

A

let is normal, let* means pay attention to bindings even within let expression and letrec means can call self in defenition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

tail recursion

A

compiler fakes iteration. Nothing needs to be done after return.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Static Length String

A

length of the string is fixed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Limited Dynamic Length String

A

size can shrink/grow but fixed max

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Dynamic Length String

A

String go brrrr

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

types of array bindings

A

static (C++ static), fixed stack dynamic (declared c++ arrays), fixed heap dynamic (C++ new array), HEAP-DYNAMIC (everything is dynamic including size).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

associative array

A

maps keys to values

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

difference between tuple and record

A

record is a named tuple

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

union

A

A type whose variables are allowed to store different type values at different times during execution

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

unification vs instantiation

A

unification means two rules match and can be merged, instantiation is when X gets replaced with the fact implied

How well did you know this?
1
Not at all
2
3
4
5
Perfectly