Update C11 standard to C17.

main
Joshua Potter 2024-12-02 05:31:29 -07:00
parent 868ea3a343
commit a830a44ecb
12 changed files with 268 additions and 259 deletions

View File

@ -0,0 +1,9 @@
---
title: "2024-12-02"
---
- [ ] Anki Flashcards
- [ ] KoL
- [ ] OGS
- [ ] Sheet Music (10 min.)
- [ ] Korean (Read 1 Story)

View File

@ -368,6 +368,6 @@ END%%
## Bibliography ## Bibliography
* Bryant, Randal E., and David O'Hallaron. *Computer Systems: A Programmer's Perspective*. Third edition, Global edition. Always Learning. Pearson, 2016. * Bryant, Randal E., and David O'Hallaron. *Computer Systems: A Programmer's Perspective*. Third edition, Global edition. Always Learning. Pearson, 2016.
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).
* Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994. * Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994.

View File

@ -152,7 +152,7 @@ Together these points imply a function prototype *must* use a parameter type lis
Basic Basic
Which of prototypes or declarations are more general? Which of prototypes or declarations are more general?
Back: Declarations. Back: Declarations.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751462--> <!--ID: 1732031751462-->
END%% END%%
@ -160,7 +160,7 @@ END%%
Basic Basic
What two ways are parameters declared in function declarations and definitions? What two ways are parameters declared in function declarations and definitions?
Back: Identifier type lists and parameter type lists. Back: Identifier type lists and parameter type lists.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751467--> <!--ID: 1732031751467-->
END%% END%%
@ -168,7 +168,7 @@ END%%
Basic Basic
Which of identifier type lists and/or parameter type lists considered obsolete? Which of identifier type lists and/or parameter type lists considered obsolete?
Back: Identifier type lists. Back: Identifier type lists.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751470--> <!--ID: 1732031751470-->
END%% END%%
@ -179,7 +179,7 @@ Back:
```c ```c
int add(x, y) int x; int y; { return x + y; } int add(x, y) int x; int y; { return x + y; }
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751473--> <!--ID: 1732031751473-->
END%% END%%
@ -190,7 +190,7 @@ Back:
```c ```c
int add(int x, int y) { return x + y; } int add(int x, int y) { return x + y; }
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751476--> <!--ID: 1732031751476-->
END%% END%%
@ -201,7 +201,7 @@ Is the following a prototype or a declaration?
void foo(); void foo();
``` ```
Back: A declaration. Back: A declaration.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751479--> <!--ID: 1732031751479-->
END%% END%%
@ -212,7 +212,7 @@ What compilation error does the following raise?
void foo(); void foo();
``` ```
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751482--> <!--ID: 1732031751482-->
END%% END%%
@ -223,7 +223,7 @@ What compilation error does the following raise?
void foo(x, y); void foo(x, y);
``` ```
Back: A function declaration cannot have a non-empty identifier list. Back: A function declaration cannot have a non-empty identifier list.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751486--> <!--ID: 1732031751486-->
END%% END%%
@ -234,7 +234,7 @@ What compilation error does the following raise?
void foo(x, y) int x; int y; void foo(x, y) int x; int y;
``` ```
Back: A function declaration cannot have a non-empty identifier list. Back: A function declaration cannot have a non-empty identifier list.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751490--> <!--ID: 1732031751490-->
END%% END%%
@ -245,7 +245,7 @@ What compilation error does the following raise?
void foo(x, y) int x; int y; {} void foo(x, y) int x; int y; {}
``` ```
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751495--> <!--ID: 1732031751495-->
END%% END%%
@ -256,7 +256,7 @@ What function prototype is declared in the following?
void foo(x, y) int x; int y; {} void foo(x, y) int x; int y; {}
``` ```
Back: N/A. No prototype has been declared. Back: N/A. No prototype has been declared.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751499--> <!--ID: 1732031751499-->
END%% END%%
@ -269,7 +269,7 @@ void foo();
int main(void) { foo(1); } int main(void) { foo(1); }
``` ```
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751504--> <!--ID: 1732031751504-->
END%% END%%
@ -280,7 +280,7 @@ Is the following a prototype or a declaration?
void f(void); void f(void);
``` ```
Back: A prototype. Back: A prototype.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751509--> <!--ID: 1732031751509-->
END%% END%%
@ -291,7 +291,7 @@ What compilation error does the following raise?
void foo(void); void foo(void);
``` ```
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751513--> <!--ID: 1732031751513-->
END%% END%%
@ -304,7 +304,7 @@ void foo(void);
int main(void) { foo(1); } int main(void) { foo(1); }
``` ```
Back: Too many arguments to function call `foo`. Back: Too many arguments to function call `foo`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751518--> <!--ID: 1732031751518-->
END%% END%%
@ -315,7 +315,7 @@ What function prototype is declared in the following?
void foo(int x, int y); void foo(int x, int y);
``` ```
Back: `void foo(int, int)` Back: `void foo(int, int)`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751522--> <!--ID: 1732031751522-->
END%% END%%
@ -326,7 +326,7 @@ What function prototype is declared in the following?
void foo(int x, int y) {} void foo(int x, int y) {}
``` ```
Back: `void foo(int, int)` Back: `void foo(int, int)`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751527--> <!--ID: 1732031751527-->
END%% END%%
@ -337,7 +337,7 @@ How many arguments does the following declaration specify?
void foo(); void foo();
``` ```
Back: Some number unknown to the compiler. Back: Some number unknown to the compiler.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751531--> <!--ID: 1732031751531-->
END%% END%%
@ -348,7 +348,7 @@ How many arguments does the following declaration specify?
void foo(void); void foo(void);
``` ```
Back: Zero. Back: Zero.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751535--> <!--ID: 1732031751535-->
END%% END%%
@ -360,7 +360,7 @@ int foo();
int foo(int a); int foo(int a);
``` ```
Back: N/A. It likely wouldn't. Back: N/A. It likely wouldn't.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751539--> <!--ID: 1732031751539-->
END%% END%%
@ -372,7 +372,7 @@ int foo();
int foo(float a); int foo(float a);
``` ```
Back: Conflicting types. The first `foo` declares any `float` passed to it default promotes to a `double`. Back: Conflicting types. The first `foo` declares any `float` passed to it default promotes to a `double`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751543--> <!--ID: 1732031751543-->
END%% END%%
@ -384,7 +384,7 @@ int foo();
int foo(char a); int foo(char a);
``` ```
Back: Conflicting types. The first `foo` declares any `char` passed to it default promotes to an `int`. Back: Conflicting types. The first `foo` declares any `char` passed to it default promotes to an `int`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751547--> <!--ID: 1732031751547-->
END%% END%%
@ -396,7 +396,7 @@ int foo();
int foo(double a); int foo(double a);
``` ```
Back: N/A. It likely wouldn't. Back: N/A. It likely wouldn't.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732031751552--> <!--ID: 1732031751552-->
END%% END%%
@ -604,5 +604,5 @@ END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).

View File

@ -61,7 +61,7 @@ The notion of a value in C is an abstract entity. It exists beyond the program o
Basic Basic
What does an object refer to? What does an object refer to?
Back: A region of data storage in the execution environment. Back: A region of data storage in the execution environment.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994830--> <!--ID: 1723510994830-->
END%% END%%
@ -69,7 +69,7 @@ END%%
Basic Basic
What does a value refer to? What does a value refer to?
Back: The contents of an object when interpreted as having a specific type. Back: The contents of an object when interpreted as having a specific type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994835--> <!--ID: 1723510994835-->
END%% END%%
@ -92,7 +92,7 @@ END%%
%%ANKI %%ANKI
Cloze Cloze
A {value} refers to the contents of an {object} when interpreted as having a specific type. A {value} refers to the contents of an {object} when interpreted as having a specific type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994839--> <!--ID: 1723510994839-->
END%% END%%
@ -100,7 +100,7 @@ END%%
Basic Basic
What is an lvalue? What is an lvalue?
Back: An expression (with non-`void` object type) that potentially designates an object. Back: An expression (with non-`void` object type) that potentially designates an object.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994874--> <!--ID: 1723510994874-->
END%% END%%
@ -108,7 +108,7 @@ END%%
Basic Basic
Why are lvalues named the way they are? Why are lvalues named the way they are?
Back: The name is an acronym for **l**ocator **value** (or **l**eft **value**). Back: The name is an acronym for **l**ocator **value** (or **l**eft **value**).
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994878--> <!--ID: 1723510994878-->
END%% END%%
@ -116,7 +116,7 @@ END%%
Basic Basic
What is an rvalue? What is an rvalue?
Back: The value of an expression. Back: The value of an expression.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994881--> <!--ID: 1723510994881-->
END%% END%%
@ -124,7 +124,7 @@ END%%
Basic Basic
Why are rvalues named the way they are? Why are rvalues named the way they are?
Back: The name is an acronym for **r**ight **value**. Back: The name is an acronym for **r**ight **value**.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994886--> <!--ID: 1723510994886-->
END%% END%%
@ -132,7 +132,7 @@ END%%
Basic Basic
Can an lvalue designate an object? Can an lvalue designate an object?
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994900--> <!--ID: 1723510994900-->
END%% END%%
@ -140,7 +140,7 @@ END%%
Basic Basic
Can an lvalue designate a function? Can an lvalue designate a function?
Back: No. Back: No.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994907--> <!--ID: 1723510994907-->
END%% END%%
@ -151,7 +151,7 @@ Is `x` an lvalue or rvalue in the following snippet?
int x = 10; int x = 10;
``` ```
Back: An lvalue. Back: An lvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994914--> <!--ID: 1723510994914-->
END%% END%%
@ -162,7 +162,7 @@ Is `int` an lvalue or rvalue in the following snippet?
int x = 10; int x = 10;
``` ```
Back: Neither. Back: Neither.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994920--> <!--ID: 1723510994920-->
END%% END%%
@ -173,7 +173,7 @@ Is `10` an lvalue or rvalue in the following snippet?
int x = 10; int x = 10;
``` ```
Back: An rvalue. Back: An rvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994925--> <!--ID: 1723510994925-->
END%% END%%
@ -184,7 +184,7 @@ Basic
int x = 10; int x = 10;
``` ```
Back: Because `x` refers to a memory location. Back: Because `x` refers to a memory location.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994932--> <!--ID: 1723510994932-->
END%% END%%
@ -195,7 +195,7 @@ Is `x` an lvalue or rvalue in the following snippet?
void x; void x;
``` ```
Back: Neither. Back: Neither.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994939--> <!--ID: 1723510994939-->
END%% END%%
@ -206,7 +206,7 @@ Is `x` an lvalue or rvalue in the following snippet?
void *x; void *x;
``` ```
Back: An lvalue. Back: An lvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994945--> <!--ID: 1723510994945-->
END%% END%%
@ -217,7 +217,7 @@ Is `y` an lvalue or rvalue in the following snippet?
int y = x + 10; int y = x + 10;
``` ```
Back: An lvalue. Back: An lvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994952--> <!--ID: 1723510994952-->
END%% END%%
@ -228,7 +228,7 @@ Is `x` an lvalue or rvalue in the following snippet?
int y = x + 10; int y = x + 10;
``` ```
Back: An rvalue. Back: An rvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994958--> <!--ID: 1723510994958-->
END%% END%%
@ -240,7 +240,7 @@ int *ptr = &x;
*ptr = 10; *ptr = 10;
``` ```
Back: An lvalue. Back: An lvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994964--> <!--ID: 1723510994964-->
END%% END%%
@ -252,7 +252,7 @@ int *ptr = &x;
*ptr = 10; *ptr = 10;
``` ```
Back: An lvalue. Back: An lvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994970--> <!--ID: 1723510994970-->
END%% END%%
@ -265,7 +265,7 @@ int getValue () {
} }
``` ```
Back: Neither. Back: Neither.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994975--> <!--ID: 1723510994975-->
END%% END%%
@ -276,7 +276,7 @@ Is `getValue()` an lvalue or rvalue in the following snippet?
int d = getValue(); int d = getValue();
``` ```
Back: An rvalue. Back: An rvalue.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994980--> <!--ID: 1723510994980-->
END%% END%%
@ -289,7 +289,7 @@ int getValue() {
} }
``` ```
Back: The function name is just syntax. That is, it isn't an expression. Back: The function name is just syntax. That is, it isn't an expression.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994984--> <!--ID: 1723510994984-->
END%% END%%
@ -297,7 +297,7 @@ END%%
Basic Basic
Are variables typically lvalues or rvalues? Are variables typically lvalues or rvalues?
Back: lvalues. Back: lvalues.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994988--> <!--ID: 1723510994988-->
END%% END%%
@ -305,7 +305,7 @@ END%%
Basic Basic
Are constants typically lvalues or rvalues? Are constants typically lvalues or rvalues?
Back: rvalues. Back: rvalues.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994992--> <!--ID: 1723510994992-->
END%% END%%
@ -313,7 +313,7 @@ END%%
Basic Basic
Are array accesses typically lvalues or rvalues? Are array accesses typically lvalues or rvalues?
Back: lvalues. Back: lvalues.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994997--> <!--ID: 1723510994997-->
END%% END%%
@ -321,7 +321,7 @@ END%%
Basic Basic
Are dereferenced pointers typically lvalues or rvalues? Are dereferenced pointers typically lvalues or rvalues?
Back: lvalues. Back: lvalues.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510995001--> <!--ID: 1723510995001-->
END%% END%%
@ -329,7 +329,7 @@ END%%
Basic Basic
Are temporary values typically lvalues or rvalues? Are temporary values typically lvalues or rvalues?
Back: rvalues. Back: rvalues.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510995006--> <!--ID: 1723510995006-->
END%% END%%
@ -428,5 +428,5 @@ END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).

View File

@ -29,7 +29,7 @@ END%%
Basic Basic
What capability does linkage allow identifiers to perform? What capability does linkage allow identifiers to perform?
Back: Reference to the same object or function. Back: Reference to the same object or function.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193275--> <!--ID: 1733010193275-->
END%% END%%
@ -37,7 +37,7 @@ END%%
Basic Basic
What are the three kinds of linkage? What are the three kinds of linkage?
Back: External, internal, and none. Back: External, internal, and none.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193276--> <!--ID: 1733010193276-->
END%% END%%
@ -45,7 +45,7 @@ END%%
Basic Basic
External linkage denotes the same object across what? External linkage denotes the same object across what?
Back: The entire program. Back: The entire program.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193277--> <!--ID: 1733010193277-->
END%% END%%
@ -53,7 +53,7 @@ END%%
Basic Basic
Internal linkage denotes the same object across what? Internal linkage denotes the same object across what?
Back: A single translation unit. Back: A single translation unit.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193278--> <!--ID: 1733010193278-->
END%% END%%
@ -61,7 +61,7 @@ END%%
Basic Basic
What is the linkage between two different identifiers? What is the linkage between two different identifiers?
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193279--> <!--ID: 1733010193279-->
END%% END%%
@ -69,7 +69,7 @@ END%%
Basic Basic
Which keyword is usually associated with external linkage? Which keyword is usually associated with external linkage?
Back: `extern` Back: `extern`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193280--> <!--ID: 1733010193280-->
END%% END%%
@ -77,7 +77,7 @@ END%%
Basic Basic
What linkage does a keyword annotated with `extern` have? What linkage does a keyword annotated with `extern` have?
Back: Internal or external. Back: Internal or external.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193281--> <!--ID: 1733010193281-->
END%% END%%
@ -85,7 +85,7 @@ END%%
Basic Basic
What linkage does a keyword associated with `static` have? What linkage does a keyword associated with `static` have?
Back: Internal. Back: Internal.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193282--> <!--ID: 1733010193282-->
END%% END%%
@ -93,7 +93,7 @@ END%%
Basic Basic
Which keyword is usually associated with internal linkage? Which keyword is usually associated with internal linkage?
Back: `static` Back: `static`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193283--> <!--ID: 1733010193283-->
END%% END%%
@ -101,7 +101,7 @@ END%%
Basic Basic
When can an identifier have both external and internal linkage? When can an identifier have both external and internal linkage?
Back: When specified in two different translation units. Back: When specified in two different translation units.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193284--> <!--ID: 1733010193284-->
END%% END%%
@ -109,7 +109,7 @@ END%%
Basic Basic
Within a translation unit, what happens if an identifer has both external and internal linkage? Within a translation unit, what happens if an identifer has both external and internal linkage?
Back: Undefined behavior. Back: Undefined behavior.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193285--> <!--ID: 1733010193285-->
END%% END%%
@ -120,7 +120,7 @@ Consider the following translation unit. What is the linkage of `x`?
int x; int x;
``` ```
Back: External. Back: External.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193286--> <!--ID: 1733010193286-->
END%% END%%
@ -131,7 +131,7 @@ Consider the following translation unit. What is the linkage of `foo`?
void foo(void) { } void foo(void) { }
``` ```
Back: External. Back: External.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193287--> <!--ID: 1733010193287-->
END%% END%%
@ -139,7 +139,7 @@ END%%
Basic Basic
What is the linkage of an object identifier with file scope and no storage-class specifier? What is the linkage of an object identifier with file scope and no storage-class specifier?
Back: External. Back: External.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193288--> <!--ID: 1733010193288-->
END%% END%%
@ -147,7 +147,7 @@ END%%
Basic Basic
*How* do you identify the linkage of an object identifier with file scope and no storage-class specifier? *How* do you identify the linkage of an object identifier with file scope and no storage-class specifier?
Back: Its always external. Back: Its always external.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193289--> <!--ID: 1733010193289-->
END%% END%%
@ -159,7 +159,7 @@ int x;
static int x; static int x;
``` ```
Back: N/A. Undefined behavior. Back: N/A. Undefined behavior.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733022430503--> <!--ID: 1733022430503-->
END%% END%%
@ -167,7 +167,7 @@ END%%
Basic Basic
What is the linkage of a function identifier with file scope and no storage-class specifier? What is the linkage of a function identifier with file scope and no storage-class specifier?
Back: Internal or external. Back: Internal or external.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193290--> <!--ID: 1733010193290-->
END%% END%%
@ -179,7 +179,7 @@ static void foo(void);
extern void foo(void); extern void foo(void);
``` ```
Back: Internal. Back: Internal.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193291--> <!--ID: 1733010193291-->
END%% END%%
@ -191,7 +191,7 @@ extern void foo(void);
static void foo(void); static void foo(void);
``` ```
Back: N/A. Undefined behavior. Back: N/A. Undefined behavior.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193292--> <!--ID: 1733010193292-->
END%% END%%
@ -203,7 +203,7 @@ void foo(void);
static void foo(void); static void foo(void);
``` ```
Back: N/A. Undefined behavior. Back: N/A. Undefined behavior.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193293--> <!--ID: 1733010193293-->
END%% END%%
@ -215,7 +215,7 @@ void foo(void);
void foo(void); void foo(void);
``` ```
Back: External. Back: External.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193294--> <!--ID: 1733010193294-->
END%% END%%
@ -223,7 +223,7 @@ END%%
Basic Basic
*How* do you identify the linkage of a function identifier with file scope and no storage-class specifier? *How* do you identify the linkage of a function identifier with file scope and no storage-class specifier?
Back: Its the same as if the function identifier were declared `extern`. Back: Its the same as if the function identifier were declared `extern`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193295--> <!--ID: 1733010193295-->
END%% END%%
@ -231,7 +231,7 @@ END%%
Basic Basic
What is the linkage of a function parameter? What is the linkage of a function parameter?
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193296--> <!--ID: 1733010193296-->
END%% END%%
@ -239,7 +239,7 @@ END%%
Basic Basic
What is the linkage of a local variable without a storage specified? What is the linkage of a local variable without a storage specified?
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193297--> <!--ID: 1733010193297-->
END%% END%%
@ -251,7 +251,7 @@ int x;
int main(void) { extern int x; } int main(void) { extern int x; }
``` ```
Back: External. Back: External.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: ““ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193298--> <!--ID: 1733010193298-->
END%% END%%
@ -263,7 +263,7 @@ int x;
int main(void) { static int x; } int main(void) { static int x; }
``` ```
Back: Internal. Back: Internal.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193299--> <!--ID: 1733010193299-->
END%% END%%
@ -275,7 +275,7 @@ extern int x;
int main(void) { static int x; } int main(void) { static int x; }
``` ```
Back: Internal. Back: Internal.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193300--> <!--ID: 1733010193300-->
END%% END%%
@ -287,7 +287,7 @@ extern int x;
int main(void) { extern int x; } int main(void) { extern int x; }
``` ```
Back: External. Back: External.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193301--> <!--ID: 1733010193301-->
END%% END%%
@ -300,7 +300,7 @@ extern int x;
int main(void) { extern int x; } int main(void) { extern int x; }
``` ```
Back: Internal. Back: Internal.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193302--> <!--ID: 1733010193302-->
END%% END%%
@ -313,7 +313,7 @@ static int x;
int main(void) { extern int x; } int main(void) { extern int x; }
``` ```
Back: N/A. Undefined behavior. Back: N/A. Undefined behavior.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193303--> <!--ID: 1733010193303-->
END%% END%%
@ -325,7 +325,7 @@ extern int x;
int main(void) { int x; } int main(void) { int x; }
``` ```
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193304--> <!--ID: 1733010193304-->
END%% END%%
@ -337,7 +337,7 @@ static int x;
int main(void) { int x; } int main(void) { int x; }
``` ```
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193305--> <!--ID: 1733010193305-->
END%% END%%
@ -348,11 +348,11 @@ Consider the following translation unit. What is the linkage of the last `x`?
void foo(int x) { } void foo(int x) { }
``` ```
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733010193306--> <!--ID: 1733010193306-->
END%% END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).

View File

@ -13,7 +13,7 @@ An object has a **storage duration** that determines its **lifetime**. There are
%%ANKI %%ANKI
Cloze Cloze
An {object} has a {storage duration} that determines its {lifetime}. An {object} has a {storage duration} that determines its {lifetime}.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664862--> <!--ID: 1733060664862-->
END%% END%%
@ -21,7 +21,7 @@ END%%
Basic Basic
What are the four storage durations? What are the four storage durations?
Back: Static, thread, automatic, and allocated. Back: Static, thread, automatic, and allocated.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664868--> <!--ID: 1733060664868-->
END%% END%%
@ -29,7 +29,7 @@ END%%
Basic Basic
What is an object's lifetime? What is an object's lifetime?
Back: The portion of a program execution during which storage is guaranteed to be reserved for the object. Back: The portion of a program execution during which storage is guaranteed to be reserved for the object.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664871--> <!--ID: 1733060664871-->
END%% END%%
@ -37,7 +37,7 @@ END%%
Basic Basic
What is the result of accessing an object within its lifetime? What is the result of accessing an object within its lifetime?
Back: The value last stored within the object. Back: The value last stored within the object.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664874--> <!--ID: 1733060664874-->
END%% END%%
@ -45,7 +45,7 @@ END%%
Basic Basic
What is the result of accessing an object outside its lifetime? What is the result of accessing an object outside its lifetime?
Back: Undefined behavior. Back: Undefined behavior.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664877--> <!--ID: 1733060664877-->
END%% END%%
@ -59,7 +59,7 @@ Its lifetime is the entire execution of the program and its stored value is init
Basic Basic
What is the storage duration of an object whose identifer has external linkage? What is the storage duration of an object whose identifer has external linkage?
Back: Either static or thread. Back: Either static or thread.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664881--> <!--ID: 1733060664881-->
END%% END%%
@ -67,7 +67,7 @@ END%%
Basic Basic
When; does an object whose identifier has external linkage have a static storage duration? When; does an object whose identifier has external linkage have a static storage duration?
Back: When the identifier is declared without storage-class specifier `_Thread_local`. Back: When the identifier is declared without storage-class specifier `_Thread_local`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664884--> <!--ID: 1733060664884-->
END%% END%%
@ -75,7 +75,7 @@ END%%
Basic Basic
When; does an object whose identifier has external linkage have a thread storage duration? When; does an object whose identifier has external linkage have a thread storage duration?
Back: When the identifier is declared with storage-class specifier `_Thread_local`. Back: When the identifier is declared with storage-class specifier `_Thread_local`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664888--> <!--ID: 1733060664888-->
END%% END%%
@ -83,7 +83,7 @@ END%%
Basic Basic
Which storage class specifier(s) can be used to declare an object with static storage duration? Which storage class specifier(s) can be used to declare an object with static storage duration?
Back: `extern` and `static`. Back: `extern` and `static`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022801--> <!--ID: 1733064022801-->
END%% END%%
@ -94,7 +94,7 @@ Consider the following translation unit. What is the storage duration of the obj
int x; int x;
``` ```
Back: Static. Back: Static.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664892--> <!--ID: 1733060664892-->
END%% END%%
@ -105,7 +105,7 @@ Consider the following translation unit. What is the storage duration of the obj
extern int x; extern int x;
``` ```
Back: Static. Back: Static.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664896--> <!--ID: 1733060664896-->
END%% END%%
@ -116,7 +116,7 @@ Consider the following translation unit. What is the storage duration of the obj
static int x; static int x;
``` ```
Back: Static. Back: Static.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664899--> <!--ID: 1733060664899-->
END%% END%%
@ -127,7 +127,7 @@ Consider the following translation unit. What is the storage duration of the obj
_Thread_local int x; _Thread_local int x;
``` ```
Back: Thread. Back: Thread.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664903--> <!--ID: 1733060664903-->
END%% END%%
@ -138,7 +138,7 @@ Consider the following translation unit. What is the storage duration of the obj
void foo() { static int x; } void foo() { static int x; }
``` ```
Back: Static. Back: Static.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664907--> <!--ID: 1733060664907-->
END%% END%%
@ -146,7 +146,7 @@ END%%
Basic Basic
What is the lifetime of an object with static storage duration? What is the lifetime of an object with static storage duration?
Back: The entire program execution. Back: The entire program execution.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664911--> <!--ID: 1733060664911-->
END%% END%%
@ -154,7 +154,7 @@ END%%
Basic Basic
When is an object with static storage duration initialized? When is an object with static storage duration initialized?
Back: Prior to program startup (before `main` is called). Back: Prior to program startup (before `main` is called).
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664914--> <!--ID: 1733060664914-->
END%% END%%
@ -162,7 +162,7 @@ END%%
Basic Basic
How many times can object with static storage duration be initialized? How many times can object with static storage duration be initialized?
Back: Only once. Back: Only once.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664922--> <!--ID: 1733060664922-->
END%% END%%
@ -170,7 +170,7 @@ END%%
Basic Basic
An object with static storage duration must have what linkage? An object with static storage duration must have what linkage?
Back: Internal or external. Back: Internal or external.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022808--> <!--ID: 1733064022808-->
END%% END%%
@ -184,14 +184,14 @@ Its lifetime is the entire execution of the thread for which it is created, and
Basic Basic
Which keyword declares an object with thread local storage duration? Which keyword declares an object with thread local storage duration?
Back: `_Thread_local` Back: `_Thread_local`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664926--> <!--ID: 1733060664926-->
END%% END%%
%%ANKI %%ANKI
Cloze Cloze
{1:`_Thread_local`} is a {2:keyword} whereas {2:`thread_local`} is a {1:macro}. {1:`_Thread_local`} is a {2:keyword} whereas {2:`thread_local`} is a {1:macro}.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664930--> <!--ID: 1733060664930-->
END%% END%%
@ -199,7 +199,7 @@ END%%
Basic Basic
Which library is `thread_local` defined in? Which library is `thread_local` defined in?
Back: `<threads.h>` Back: `<threads.h>`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664934--> <!--ID: 1733060664934-->
END%% END%%
@ -207,7 +207,7 @@ END%%
Basic Basic
Which storage class specifier(s) can be used to declare an object with thread storage duration? Which storage class specifier(s) can be used to declare an object with thread storage duration?
Back: `_Thread_local` Back: `_Thread_local`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022811--> <!--ID: 1733064022811-->
END%% END%%
@ -215,7 +215,7 @@ END%%
Basic Basic
What is the lifetime of an object with thread storage duration? What is the lifetime of an object with thread storage duration?
Back: The entire execution fo the thread for which it is created. Back: The entire execution fo the thread for which it is created.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664939--> <!--ID: 1733060664939-->
END%% END%%
@ -223,7 +223,7 @@ END%%
Basic Basic
When is an object with thread storage duration initialized? When is an object with thread storage duration initialized?
Back: When its corresponding thread is started. Back: When its corresponding thread is started.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733060664943--> <!--ID: 1733060664943-->
END%% END%%
@ -231,7 +231,7 @@ END%%
Basic Basic
An object with thread storage duration must have what linkage? An object with thread storage duration must have what linkage?
Back: Internal or external. Back: Internal or external.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022814--> <!--ID: 1733064022814-->
END%% END%%
@ -243,7 +243,7 @@ An object whose identifier is declared with no linkage and without the storage-c
Basic Basic
Which keyword is used to declare automatic storage duration? Which keyword is used to declare automatic storage duration?
Back: `auto` Back: `auto`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022818--> <!--ID: 1733064022818-->
END%% END%%
@ -251,7 +251,7 @@ END%%
Basic Basic
Which storage class specifier is essentially never used in modern C? Which storage class specifier is essentially never used in modern C?
Back: `auto` Back: `auto`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022821--> <!--ID: 1733064022821-->
END%% END%%
@ -259,7 +259,7 @@ END%%
Basic Basic
Which storage class specifier(s) can be used to declare an object with automatic storage duration? Which storage class specifier(s) can be used to declare an object with automatic storage duration?
Back: `auto` Back: `auto`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064332819--> <!--ID: 1733064332819-->
END%% END%%
@ -270,7 +270,7 @@ Consider the following translation unit. What is the storage duration of the obj
void foo() { int x; } void foo() { int x; }
``` ```
Back: Automatic. Back: Automatic.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022825--> <!--ID: 1733064022825-->
END%% END%%
@ -281,7 +281,7 @@ Consider the following translation unit. What is the storage duration of the obj
void foo(int x) { } void foo(int x) { }
``` ```
Back: Automatic. Back: Automatic.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022829--> <!--ID: 1733064022829-->
END%% END%%
@ -289,7 +289,7 @@ END%%
Basic Basic
An object with automatic storage duration must have what linkage? An object with automatic storage duration must have what linkage?
Back: None. Back: None.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022833--> <!--ID: 1733064022833-->
END%% END%%
@ -297,7 +297,7 @@ END%%
Basic Basic
What are the three possible lifetimes of an automatic object? What are the three possible lifetimes of an automatic object?
Back: Enclosing block, declaration scope, temporary. Back: Enclosing block, declaration scope, temporary.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022838--> <!--ID: 1733064022838-->
END%% END%%
@ -309,7 +309,7 @@ For these objects that do have a VLA type, its lifetime extends from the declara
Basic Basic
Consider non-temporary object with automatic storage duration. What property determines its lifetime? Consider non-temporary object with automatic storage duration. What property determines its lifetime?
Back: Whether or not the object has a VLA type. Back: Whether or not the object has a VLA type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022843--> <!--ID: 1733064022843-->
END%% END%%
@ -317,7 +317,7 @@ END%%
Basic Basic
When is the lifetime of an object with automatic storage duration that of its enclosing block? When is the lifetime of an object with automatic storage duration that of its enclosing block?
Back: When it is a non-temporary object with non-VLA type. Back: When it is a non-temporary object with non-VLA type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022848--> <!--ID: 1733064022848-->
END%% END%%
@ -325,7 +325,7 @@ END%%
Basic Basic
Consider non-temporary, non-VLA object with automatic storage duration. What is its lifetime? Consider non-temporary, non-VLA object with automatic storage duration. What is its lifetime?
Back: From entry into its enclosing block until execution of that block ends. Back: From entry into its enclosing block until execution of that block ends.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022853--> <!--ID: 1733064022853-->
END%% END%%
@ -333,7 +333,7 @@ END%%
Basic Basic
When does the lifetime of an object with automatic storage duration match its declaration's scope? When does the lifetime of an object with automatic storage duration match its declaration's scope?
Back: When it is a non-temporary object with VLA type. Back: When it is a non-temporary object with VLA type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022857--> <!--ID: 1733064022857-->
END%% END%%
@ -344,7 +344,7 @@ Consider the following translation unit. What is the lifetime of the object with
void foo(int x) { } void foo(int x) { }
``` ```
Back: From start of execution to end of execution of `foo`. Back: From start of execution to end of execution of `foo`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022862--> <!--ID: 1733064022862-->
END%% END%%
@ -359,7 +359,7 @@ void foo() {
} }
``` ```
Back: Between the start and end of `foo`'s execution. Back: Between the start and end of `foo`'s execution.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022867--> <!--ID: 1733064022867-->
END%% END%%
@ -374,7 +374,7 @@ void foo() {
} }
``` ```
Back: Indeterminate. Back: Indeterminate.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022873--> <!--ID: 1733064022873-->
END%% END%%
@ -389,7 +389,7 @@ void foo() {
} }
``` ```
Back: `2` Back: `2`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022877--> <!--ID: 1733064022877-->
END%% END%%
@ -404,7 +404,7 @@ void foo() {
} }
``` ```
Back: From the start to the end of execution of its surrounding block. Back: From the start to the end of execution of its surrounding block.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022882--> <!--ID: 1733064022882-->
END%% END%%
@ -419,7 +419,7 @@ void foo() {
} }
``` ```
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022887--> <!--ID: 1733064022887-->
END%% END%%
@ -434,7 +434,7 @@ void foo() {
} }
``` ```
Back: No. Back: No.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022892--> <!--ID: 1733064022892-->
END%% END%%
@ -449,7 +449,7 @@ void foo() {
} }
``` ```
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022897--> <!--ID: 1733064022897-->
END%% END%%
@ -457,7 +457,7 @@ END%%
Basic Basic
Consider non-temporary, VLA object with automatic storage duration. What is its lifetime? Consider non-temporary, VLA object with automatic storage duration. What is its lifetime?
Back: From declaration of the VLA to when it leaves its scope. Back: From declaration of the VLA to when it leaves its scope.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022901--> <!--ID: 1733064022901-->
END%% END%%
@ -472,7 +472,7 @@ void foo(int n) {
} }
``` ```
Back: No. Back: No.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022906--> <!--ID: 1733064022906-->
END%% END%%
@ -487,7 +487,7 @@ void foo(int n) {
} }
``` ```
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022912--> <!--ID: 1733064022912-->
END%% END%%
@ -502,7 +502,7 @@ void foo(int n) {
} }
``` ```
Back: Between its declaration and when `foo`'s execution ends. Back: Between its declaration and when `foo`'s execution ends.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022917--> <!--ID: 1733064022917-->
END%% END%%
@ -517,7 +517,7 @@ void foo(int n) {
} }
``` ```
Back: No. Back: No.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022923--> <!--ID: 1733064022923-->
END%% END%%
@ -532,7 +532,7 @@ void foo(int n) {
} }
``` ```
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022928--> <!--ID: 1733064022928-->
END%% END%%
@ -542,7 +542,7 @@ A non-lvalue expression with structure or union type, where the structure or uni
Basic Basic
When is the lifetime of an object with automatic storage duration temporary? When is the lifetime of an object with automatic storage duration temporary?
Back: When specifying a non-lvalue expression with `struct`/`union` type containing an array member. Back: When specifying a non-lvalue expression with `struct`/`union` type containing an array member.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022933--> <!--ID: 1733064022933-->
END%% END%%
@ -550,7 +550,7 @@ END%%
Basic Basic
Consider an object with temporary lifetime and automatic storage duration. What *must* the object's type be? Consider an object with temporary lifetime and automatic storage duration. What *must* the object's type be?
Back: Either a `struct` or `union`. Back: Either a `struct` or `union`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022938--> <!--ID: 1733064022938-->
END%% END%%
@ -558,7 +558,7 @@ END%%
Basic Basic
Consider an object with temporary lifetime and automatic storage duration. What *must* the `struct` or `union` contain? Consider an object with temporary lifetime and automatic storage duration. What *must* the `struct` or `union` contain?
Back: A member with array type. Back: A member with array type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1733064022942--> <!--ID: 1733064022942-->
END%% END%%
@ -811,5 +811,5 @@ END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).

View File

@ -1159,7 +1159,7 @@ void* memmove(void* s1, const void* s2, size_t n);
Basic Basic
What are the two primary functions provided by the standard library for copying memory? What are the two primary functions provided by the standard library for copying memory?
Back: `memcpy` and `memmove`. Back: `memcpy` and `memmove`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837986--> <!--ID: 1732843837986-->
END%% END%%
@ -1170,7 +1170,7 @@ Back:
```c ```c
void* memcpy(void* restrict s1, const void* restrict s2, size_t n); void* memcpy(void* restrict s1, const void* restrict s2, size_t n);
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837987--> <!--ID: 1732843837987-->
END%% END%%
@ -1178,7 +1178,7 @@ END%%
Basic Basic
What does the `memcpy` function do? What does the `memcpy` function do?
Back: Copies a specified number of bytes from one object to another. Back: Copies a specified number of bytes from one object to another.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837989--> <!--ID: 1732843837989-->
END%% END%%
@ -1186,7 +1186,7 @@ END%%
Basic Basic
Disregarding out of bounds errors, when does `memcpy` invoke undefined behavior? Disregarding out of bounds errors, when does `memcpy` invoke undefined behavior?
Back: When copying occurs between objects that overlap in memory. Back: When copying occurs between objects that overlap in memory.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837990--> <!--ID: 1732843837990-->
END%% END%%
@ -1194,7 +1194,7 @@ END%%
Basic Basic
What does the first argument of `memcpy` refer to? What does the first argument of `memcpy` refer to?
Back: The destination address bytes are copied to. Back: The destination address bytes are copied to.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837991--> <!--ID: 1732843837991-->
END%% END%%
@ -1202,7 +1202,7 @@ END%%
Basic Basic
What does the second argument of `memcpy` refer to? What does the second argument of `memcpy` refer to?
Back: The source address bytes are copied from. Back: The source address bytes are copied from.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837993--> <!--ID: 1732843837993-->
END%% END%%
@ -1210,7 +1210,7 @@ END%%
Basic Basic
What does the third argument of `memcpy` refer to? What does the third argument of `memcpy` refer to?
Back: The number of bytes to copy from the source address. Back: The number of bytes to copy from the source address.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837994--> <!--ID: 1732843837994-->
END%% END%%
@ -1218,7 +1218,7 @@ END%%
Basic Basic
Which of `memcpy` or `memmove` is faster? Which of `memcpy` or `memmove` is faster?
Back: `memcpy` Back: `memcpy`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837995--> <!--ID: 1732843837995-->
END%% END%%
@ -1226,7 +1226,7 @@ END%%
Basic Basic
*Why* is `memmove` slower than `memcpy`? *Why* is `memmove` slower than `memcpy`?
Back: It's implemented as if copying first into a temporary array that does not overlap the arguments in memory. Back: It's implemented as if copying first into a temporary array that does not overlap the arguments in memory.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837996--> <!--ID: 1732843837996-->
END%% END%%
@ -1234,7 +1234,7 @@ END%%
Basic Basic
When should you prefer using `memcpy` instead of `memmove`? When should you prefer using `memcpy` instead of `memmove`?
Back: When the copying occurs between objects that do not overlap in memory. Back: When the copying occurs between objects that do not overlap in memory.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837997--> <!--ID: 1732843837997-->
END%% END%%
@ -1242,7 +1242,7 @@ END%%
Basic Basic
Which standard header library defines `memcpy`? Which standard header library defines `memcpy`?
Back: `<string.h>` Back: `<string.h>`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837998--> <!--ID: 1732843837998-->
END%% END%%
@ -1253,7 +1253,7 @@ Back:
```c ```c
void* memmove(void* s1, const void* s2, size_t n); void* memmove(void* s1, const void* s2, size_t n);
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843837999--> <!--ID: 1732843837999-->
END%% END%%
@ -1261,7 +1261,7 @@ END%%
Basic Basic
What does the first argument of `memmove` refer to? What does the first argument of `memmove` refer to?
Back: The destination address bytes are copied to. Back: The destination address bytes are copied to.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838000--> <!--ID: 1732843838000-->
END%% END%%
@ -1269,7 +1269,7 @@ END%%
Basic Basic
What does the second argument of `memmove` refer to? What does the second argument of `memmove` refer to?
Back: The source address bytes are copied from. Back: The source address bytes are copied from.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838001--> <!--ID: 1732843838001-->
END%% END%%
@ -1277,7 +1277,7 @@ END%%
Basic Basic
What does the third argument of `memmove` refer to? What does the third argument of `memmove` refer to?
Back: The number of bytes to copy from the source address. Back: The number of bytes to copy from the source address.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838002--> <!--ID: 1732843838002-->
END%% END%%
@ -1285,7 +1285,7 @@ END%%
Basic Basic
Disregarding out of bounds errors, when does `memmove` invoke undefined behavior? Disregarding out of bounds errors, when does `memmove` invoke undefined behavior?
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838003--> <!--ID: 1732843838003-->
END%% END%%
@ -1293,7 +1293,7 @@ END%%
Basic Basic
When should you prefer using `memmove` instead of `memcopy`? When should you prefer using `memmove` instead of `memcopy`?
Back: When the copying occurs between objects that overlap in memory. Back: When the copying occurs between objects that overlap in memory.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838004--> <!--ID: 1732843838004-->
END%% END%%
@ -1301,7 +1301,7 @@ END%%
Basic Basic
Which standard header library defines `memmove`? Which standard header library defines `memmove`?
Back: `<string.h>` Back: `<string.h>`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838005--> <!--ID: 1732843838005-->
END%% END%%
@ -1309,7 +1309,7 @@ END%%
Basic Basic
What does the `memmove` function do? What does the `memmove` function do?
Back: Copies a specified number of bytes from one object to another. Back: Copies a specified number of bytes from one object to another.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732843838006--> <!--ID: 1732843838006-->
END%% END%%
@ -1318,7 +1318,7 @@ END%%
* Arnold D. Robbins, “GAWK: Effective AWK Programming,” October 2023, [https://www.gnu.org/software/gawk/manual/gawk.pdf](https://www.gnu.org/software/gawk/manual/gawk.pdf). * Arnold D. Robbins, “GAWK: Effective AWK Programming,” October 2023, [https://www.gnu.org/software/gawk/manual/gawk.pdf](https://www.gnu.org/software/gawk/manual/gawk.pdf).
* Brian W. Kernighan and Dennis M. Ritchie, *The C Programming Language*, 2nd ed (Englewood Cliffs, N.J: Prentice Hall, 1988). * Brian W. Kernighan and Dennis M. Ritchie, *The C Programming Language*, 2nd ed (Englewood Cliffs, N.J: Prentice Hall, 1988).
* Bryant, Randal E., and David O'Hallaron. *Computer Systems: A Programmer's Perspective*. Third edition, Global edition. Always Learning. Pearson, 2016. * Bryant, Randal E., and David O'Hallaron. *Computer Systems: A Programmer's Perspective*. Third edition, Global edition. Always Learning. Pearson, 2016.
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).
* Mendel Cooper, “Advanced Bash-Scripting Guide,” n.d., 916. * Mendel Cooper, “Advanced Bash-Scripting Guide,” n.d., 916.
* “Printf,” in *Wikipedia*, January 18, 2024, [https://en.wikipedia.org/w/index.php?title=Printf&oldid=1196716962](https://en.wikipedia.org/w/index.php?title=Printf&oldid=1196716962). * “Printf,” in *Wikipedia*, January 18, 2024, [https://en.wikipedia.org/w/index.php?title=Printf&oldid=1196716962](https://en.wikipedia.org/w/index.php?title=Printf&oldid=1196716962).

View File

@ -67,7 +67,7 @@ END%%
Basic Basic
What header defines `size_t`? What header defines `size_t`?
Back: `<stddef.h>` Back: `<stddef.h>`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730740461658--> <!--ID: 1730740461658-->
END%% END%%
@ -75,7 +75,7 @@ END%%
Basic Basic
What header defines `ptrdiff_t`? What header defines `ptrdiff_t`?
Back: `<stddef.h>` Back: `<stddef.h>`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730740461659--> <!--ID: 1730740461659-->
END%% END%%
@ -83,7 +83,7 @@ END%%
Basic Basic
`ptrdiff_t` is used as the type of what result? `ptrdiff_t` is used as the type of what result?
Back: Subtracting two pointers. Back: Subtracting two pointers.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730740461660--> <!--ID: 1730740461660-->
END%% END%%
@ -91,7 +91,7 @@ END%%
Basic Basic
`size_t` is used as the type of what result? `size_t` is used as the type of what result?
Back: The `sizeof` operation. Back: The `sizeof` operation.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730740461661--> <!--ID: 1730740461661-->
END%% END%%
@ -99,7 +99,7 @@ END%%
Basic Basic
Is `ptrdiff_t` signed or unsigned? Is `ptrdiff_t` signed or unsigned?
Back: Signed. Back: Signed.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730740461662--> <!--ID: 1730740461662-->
END%% END%%
@ -141,7 +141,7 @@ END%%
Basic Basic
Is `size_t` signed or unsigned? Is `size_t` signed or unsigned?
Back: Unsigned. Back: Unsigned.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730740461663--> <!--ID: 1730740461663-->
END%% END%%
@ -155,6 +155,6 @@ END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).
* Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994. * Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994.

View File

@ -243,7 +243,7 @@ Back:
```c ```c
void foo(int *const a) {} void foo(int *const a) {}
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147585--> <!--ID: 1728244147585-->
END%% END%%
@ -257,7 +257,7 @@ Back:
```c ```c
void foo(const int *a) {} void foo(const int *a) {}
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147614--> <!--ID: 1728244147614-->
END%% END%%
@ -271,7 +271,7 @@ Back:
```c ```c
void foo(int a[restrict]) {} void foo(int a[restrict]) {}
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147617--> <!--ID: 1728244147617-->
END%% END%%
@ -285,7 +285,7 @@ Back:
```c ```c
void foo(volatile int a[]) {} void foo(volatile int a[]) {}
``` ```
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147620--> <!--ID: 1728244147620-->
END%% END%%
@ -296,7 +296,7 @@ What does the `3` keyword guarantee to the compiler?
void bar(int a[3]); void bar(int a[3]);
``` ```
Back: N/A. It is ignored. Back: N/A. It is ignored.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147623--> <!--ID: 1728244147623-->
END%% END%%
@ -307,7 +307,7 @@ Basic
void bar(int a[3]); void bar(int a[3]);
``` ```
Back: It serves as documentation. Back: It serves as documentation.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147625--> <!--ID: 1728244147625-->
END%% END%%
@ -318,7 +318,7 @@ In the following, what does the `static` keyword guarantee to the compiler?
void bar(int a[static 3]); void bar(int a[static 3]);
``` ```
Back: The minimum number of elements for the compiler to assume `a` contains. Back: The minimum number of elements for the compiler to assume `a` contains.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147628--> <!--ID: 1728244147628-->
END%% END%%
@ -334,7 +334,7 @@ int main() {
} }
``` ```
Back: N/A. It doesn't. Back: N/A. It doesn't.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147652--> <!--ID: 1728244147652-->
END%% END%%
@ -350,7 +350,7 @@ int main() {
} }
``` ```
Back: Because the argument to `foo` does not have at least `3` elements. Back: Because the argument to `foo` does not have at least `3` elements.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147655--> <!--ID: 1728244147655-->
END%% END%%
@ -366,7 +366,7 @@ int main() {
} }
``` ```
Back: N/A. It doesn't. Back: N/A. It doesn't.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147658--> <!--ID: 1728244147658-->
END%% END%%
@ -381,7 +381,7 @@ int main() {
} }
``` ```
Back: N/A. It doesn't. Back: N/A. It doesn't.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147661--> <!--ID: 1728244147661-->
END%% END%%
@ -396,7 +396,7 @@ int main() {
} }
``` ```
Back: Because `static` indicates a valid pointer must be passed to `foo`. Back: Because `static` indicates a valid pointer must be passed to `foo`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1728244147664--> <!--ID: 1728244147664-->
END%% END%%
@ -874,6 +874,6 @@ Functions are another type of derived type. They are listed in more detail [[c17
## Bibliography ## Bibliography
* Bryant, Randal E., and David O'Hallaron. *Computer Systems: A Programmer's Perspective*. Third edition, Global edition. Always Learning. Pearson, 2016. * Bryant, Randal E., and David O'Hallaron. *Computer Systems: A Programmer's Perspective*. Third edition, Global edition. Always Learning. Pearson, 2016.
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).
* Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994. * Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994.

View File

@ -14,7 +14,7 @@ Types in C are categorized corresponding to a hierarchy with a foundation compri
Basic Basic
What is the foundational category of types? What is the foundational category of types?
Back: The simple types. Back: The simple types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734400--> <!--ID: 1724546734400-->
END%% END%%
@ -22,7 +22,7 @@ END%%
Basic Basic
Why are "simple types" named the way they are? Why are "simple types" named the way they are?
Back: These types are primitives in the type hierarchy. Back: These types are primitives in the type hierarchy.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734408--> <!--ID: 1724546734408-->
END%% END%%
@ -30,7 +30,7 @@ END%%
Basic Basic
Why are "real types" named the way they are? Why are "real types" named the way they are?
Back: They refer to types that belong to $\mathbb{R}$. Back: They refer to types that belong to $\mathbb{R}$.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734411--> <!--ID: 1724546734411-->
END%% END%%
@ -38,7 +38,7 @@ END%%
Basic Basic
Why are "real types" named the way they are? Why are "real types" named the way they are?
Back: They refer to types that belong to $\mathbb{C}$. Back: They refer to types that belong to $\mathbb{C}$.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
END%% END%%
All types are categorized as **function types** or **object types**. An object type is **complete** if there is sufficient information to determine the size of objects of that type. Otherwise we say it is **incomplete**. All types are categorized as **function types** or **object types**. An object type is **complete** if there is sufficient information to determine the size of objects of that type. Otherwise we say it is **incomplete**.
@ -47,7 +47,7 @@ All types are categorized as **function types** or **object types**. An object t
Basic Basic
Types are partitioned into what two top-level categories? Types are partitioned into what two top-level categories?
Back: Object types and function types. Back: Object types and function types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994842--> <!--ID: 1723510994842-->
END%% END%%
@ -55,7 +55,7 @@ END%%
Basic Basic
What is an object type? What is an object type?
Back: A type that describes objects. Back: A type that describes objects.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994846--> <!--ID: 1723510994846-->
END%% END%%
@ -63,7 +63,7 @@ END%%
Basic Basic
What is a function type? What is a function type?
Back: A type that describes functions. Back: A type that describes functions.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994851--> <!--ID: 1723510994851-->
END%% END%%
@ -71,7 +71,7 @@ END%%
Basic Basic
What two parts characterize a function type? What two parts characterize a function type?
Back: The return type and the number/types of its parameters. Back: The return type and the number/types of its parameters.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994856--> <!--ID: 1723510994856-->
END%% END%%
@ -79,7 +79,7 @@ END%%
Basic Basic
What does it mean for an object type to be complete? What does it mean for an object type to be complete?
Back: There is sufficient information to determine the size of objects of that type. Back: There is sufficient information to determine the size of objects of that type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994866--> <!--ID: 1723510994866-->
END%% END%%
@ -87,7 +87,7 @@ END%%
Basic Basic
What does it mean for an object type to be incomplete? What does it mean for an object type to be incomplete?
Back: There is insufficient information to determine the size of objects of that type. Back: There is insufficient information to determine the size of objects of that type.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994870--> <!--ID: 1723510994870-->
END%% END%%
@ -98,7 +98,7 @@ Does `x` have complete or incomplete object type in the following?
void x; void x;
``` ```
Back: Incomplete. Back: Incomplete.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510995010--> <!--ID: 1723510995010-->
END%% END%%
@ -109,7 +109,7 @@ Does `x` have complete or incomplete object type in the following?
int x; int x;
``` ```
Back: Complete. Back: Complete.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510995016--> <!--ID: 1723510995016-->
END%% END%%
@ -120,7 +120,7 @@ Does `x` have complete or incomplete object type in the following?
void *x; void *x;
``` ```
Back: Complete. Back: Complete.
Reference: ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510995023--> <!--ID: 1723510995023-->
END%% END%%
@ -161,7 +161,7 @@ END%%
Basic Basic
What object type can an lvalue *not* have? What object type can an lvalue *not* have?
Back: `void` Back: `void`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994890--> <!--ID: 1723510994890-->
END%% END%%
@ -169,7 +169,7 @@ END%%
Basic Basic
What object type can an lvalue have? What object type can an lvalue have?
Back: Any object type other than `void`. Back: Any object type other than `void`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1723510994895--> <!--ID: 1723510994895-->
END%% END%%
@ -181,7 +181,7 @@ The **basic types** comprise of `char`, the signed/unsigned integer types, and t
Basic Basic
Are the basic types a subset of object types or function types? Are the basic types a subset of object types or function types?
Back: Object types. Back: Object types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734414--> <!--ID: 1724546734414-->
END%% END%%
@ -189,7 +189,7 @@ END%%
Basic Basic
The basic types consist of what simple types? The basic types consist of what simple types?
Back: `char`, signed/unsigned integer types, and the floating point types. Back: `char`, signed/unsigned integer types, and the floating point types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734417--> <!--ID: 1724546734417-->
END%% END%%
@ -197,7 +197,7 @@ END%%
Basic Basic
Is `int` considered a basic type? Is `int` considered a basic type?
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734421--> <!--ID: 1724546734421-->
END%% END%%
@ -205,7 +205,7 @@ END%%
Basic Basic
Is `char` considered a simple type? Is `char` considered a simple type?
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734424--> <!--ID: 1724546734424-->
END%% END%%
@ -213,7 +213,7 @@ END%%
Basic Basic
Is `float complex` considered a simple type? Is `float complex` considered a simple type?
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734428--> <!--ID: 1724546734428-->
END%% END%%
@ -225,7 +225,7 @@ The **integer types** comprise of `char`, the signed/unsigned integer types, and
Basic Basic
Are the integer types a subset of object types or function types? Are the integer types a subset of object types or function types?
Back: Object types. Back: Object types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734431--> <!--ID: 1724546734431-->
END%% END%%
@ -233,7 +233,7 @@ END%%
Basic Basic
The integer types consist of what simple types? The integer types consist of what simple types?
Back: `char`, (un)signed integer types, and `enum`s. Back: `char`, (un)signed integer types, and `enum`s.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734436--> <!--ID: 1724546734436-->
END%% END%%
@ -241,7 +241,7 @@ END%%
Basic Basic
Is `enum` considered a simple type? Is `enum` considered a simple type?
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734439--> <!--ID: 1724546734439-->
END%% END%%
@ -249,7 +249,7 @@ END%%
Basic Basic
Is `enum` considered a basic type? Is `enum` considered a basic type?
Back: No. Back: No.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734443--> <!--ID: 1724546734443-->
END%% END%%
@ -257,7 +257,7 @@ END%%
Basic Basic
Is `enum` considered a complex type? Is `enum` considered a complex type?
Back: No. Back: No.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734447--> <!--ID: 1724546734447-->
END%% END%%
@ -265,7 +265,7 @@ END%%
Basic Basic
Is `enum` considered a real type? Is `enum` considered a real type?
Back: Yes. Back: Yes.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734452--> <!--ID: 1724546734452-->
END%% END%%
@ -273,7 +273,7 @@ END%%
Basic Basic
What category of types is considered a basic type but not an integer type? What category of types is considered a basic type but not an integer type?
Back: Floating point types. Back: Floating point types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734458--> <!--ID: 1724546734458-->
END%% END%%
@ -281,7 +281,7 @@ END%%
Basic Basic
What category of types is considered an integer type but not a basic type? What category of types is considered an integer type but not a basic type?
Back: Enumerated types. Back: Enumerated types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734463--> <!--ID: 1724546734463-->
END%% END%%
@ -289,7 +289,7 @@ END%%
Basic Basic
Which types are considered both basic types and integer types? Which types are considered both basic types and integer types?
Back: `char` and the (un)signed integer types. Back: `char` and the (un)signed integer types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734469--> <!--ID: 1724546734469-->
END%% END%%
@ -297,7 +297,7 @@ END%%
Basic Basic
Which of basic types or integer types is a subset of the other? Which of basic types or integer types is a subset of the other?
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734477--> <!--ID: 1724546734477-->
END%% END%%
@ -308,7 +308,7 @@ Integer and floating point types are collectively called **arithmetic types**. E
%%ANKI %%ANKI
Cloze Cloze
Integer and floating point types are collectively called {arithmetic} types. Integer and floating point types are collectively called {arithmetic} types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977383--> <!--ID: 1724543977383-->
END%% END%%
@ -329,7 +329,7 @@ END%%
%%ANKI %%ANKI
Cloze Cloze
The {real} types contrast the {complex} types. The {real} types contrast the {complex} types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977387--> <!--ID: 1724543977387-->
END%% END%%
@ -337,7 +337,7 @@ END%%
Basic Basic
Which two smaller category of types make up the arithmetic types? Which two smaller category of types make up the arithmetic types?
Back: The integer and floating point types. Back: The integer and floating point types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977391--> <!--ID: 1724543977391-->
END%% END%%
@ -345,7 +345,7 @@ END%%
Basic Basic
The arithmetic types are categorized into what type domains? The arithmetic types are categorized into what type domains?
Back: The real type domain and the complex type domain. Back: The real type domain and the complex type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977395--> <!--ID: 1724543977395-->
END%% END%%
@ -353,7 +353,7 @@ END%%
Basic Basic
Which type domain does `int` fall under? Which type domain does `int` fall under?
Back: The real type domain. Back: The real type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977399--> <!--ID: 1724543977399-->
END%% END%%
@ -361,7 +361,7 @@ END%%
Basic Basic
Which type domain does `float complex` fall under? Which type domain does `float complex` fall under?
Back: The complex type domain. Back: The complex type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977404--> <!--ID: 1724543977404-->
END%% END%%
@ -369,7 +369,7 @@ END%%
Basic Basic
Which type domain does `float` fall under? Which type domain does `float` fall under?
Back: The real type domain. Back: The real type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977408--> <!--ID: 1724543977408-->
END%% END%%
@ -377,7 +377,7 @@ END%%
Basic Basic
Which type domain does `long double` fall under? Which type domain does `long double` fall under?
Back: The real type domain. Back: The real type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977412--> <!--ID: 1724543977412-->
END%% END%%
@ -385,7 +385,7 @@ END%%
Basic Basic
Which type domain does `bool` fall under? Which type domain does `bool` fall under?
Back: The real type domain. Back: The real type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977417--> <!--ID: 1724543977417-->
END%% END%%
@ -393,7 +393,7 @@ END%%
Basic Basic
Which type domain does `double complex` fall under? Which type domain does `double complex` fall under?
Back: The complex type domain. Back: The complex type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724543977422--> <!--ID: 1724543977422-->
END%% END%%
@ -401,7 +401,7 @@ END%%
Basic Basic
Which of basic types or arithmetic types is a subset of the other? Which of basic types or arithmetic types is a subset of the other?
Back: Basic types is a subset of arithmetic types. Back: Basic types is a subset of arithmetic types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734484--> <!--ID: 1724546734484-->
END%% END%%
@ -409,7 +409,7 @@ END%%
Basic Basic
Which of arithmetic types or integer types is a subset of the other? Which of arithmetic types or integer types is a subset of the other?
Back: Integer types is a subset of arithmetic types. Back: Integer types is a subset of arithmetic types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734489--> <!--ID: 1724546734489-->
END%% END%%
@ -417,7 +417,7 @@ END%%
Basic Basic
Which of the real types or integer types is a subset of the other? Which of the real types or integer types is a subset of the other?
Back: The integer types is a subset of the real types. Back: The integer types is a subset of the real types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734493--> <!--ID: 1724546734493-->
END%% END%%
@ -425,7 +425,7 @@ END%%
Basic Basic
Which of the real types or floating point types is a subset of the other? Which of the real types or floating point types is a subset of the other?
Back: N/A. Back: N/A.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734498--> <!--ID: 1724546734498-->
END%% END%%
@ -433,7 +433,7 @@ END%%
Basic Basic
Which types belong to the intersection of real and floating point types? Which types belong to the intersection of real and floating point types?
Back: Floating point types in the real type domain. Back: Floating point types in the real type domain.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546734502--> <!--ID: 1724546734502-->
END%% END%%
@ -469,7 +469,7 @@ long double a;
long double complex b; long double complex b;
``` ```
Back: `long double` Back: `long double`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203391--> <!--ID: 1724762203391-->
END%% END%%
@ -481,7 +481,7 @@ long double a;
long complex b; long complex b;
``` ```
Back: `long double` Back: `long double`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203395--> <!--ID: 1724762203395-->
END%% END%%
@ -493,7 +493,7 @@ long double a;
long complex b; long complex b;
``` ```
Back: Complex. Back: Complex.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203398--> <!--ID: 1724762203398-->
END%% END%%
@ -505,7 +505,7 @@ double complex a;
long b; long b;
``` ```
Back: `double` Back: `double`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203402--> <!--ID: 1724762203402-->
END%% END%%
@ -517,7 +517,7 @@ long double a;
long complex b; long complex b;
``` ```
Back: Complex. Back: Complex.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
END%% END%%
%%ANKI %%ANKI
@ -528,7 +528,7 @@ float a;
double b; double b;
``` ```
Back: `double` Back: `double`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203405--> <!--ID: 1724762203405-->
END%% END%%
@ -540,7 +540,7 @@ long long a;
float b; float b;
``` ```
Back: `float` Back: `float`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203408--> <!--ID: 1724762203408-->
END%% END%%
@ -552,7 +552,7 @@ long long a;
float b; float b;
``` ```
Back: Real. Back: Real.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203419--> <!--ID: 1724762203419-->
END%% END%%
@ -564,7 +564,7 @@ long long a;
float b; float b;
``` ```
Back: Because floating-point types have priority over integer types. Back: Because floating-point types have priority over integer types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203427--> <!--ID: 1724762203427-->
END%% END%%
@ -576,7 +576,7 @@ long long a;
long long b; long long b;
``` ```
Back: Real. Back: Real.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203431--> <!--ID: 1724762203431-->
END%% END%%
@ -588,7 +588,7 @@ long long a;
long long b; long long b;
``` ```
Back: `long long` Back: `long long`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203436--> <!--ID: 1724762203436-->
END%% END%%
@ -600,7 +600,7 @@ unsigned int a;
signed short b; signed short b;
``` ```
Back: `unsigned int` Back: `unsigned int`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203440--> <!--ID: 1724762203440-->
END%% END%%
@ -612,7 +612,7 @@ unsigned a;
signed int b; signed int b;
``` ```
Back: `unsigned` Back: `unsigned`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203445--> <!--ID: 1724762203445-->
END%% END%%
@ -624,7 +624,7 @@ unsigned a;
signed int b; signed int b;
``` ```
Back: Because `unsigned` has rank $\geq$ that of `signed int`. Back: Because `unsigned` has rank $\geq$ that of `signed int`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203450--> <!--ID: 1724762203450-->
END%% END%%
@ -636,7 +636,7 @@ unsigned a;
signed int b; signed int b;
``` ```
Back: Real. Back: Real.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203454--> <!--ID: 1724762203454-->
END%% END%%
@ -648,7 +648,7 @@ unsigned short a;
signed int b; signed int b;
``` ```
Back: Real. Back: Real.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203469--> <!--ID: 1724762203469-->
END%% END%%
@ -660,7 +660,7 @@ unsigned short a;
signed int b; signed int b;
``` ```
Back: Indeterminate. Back: Indeterminate.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1726840632804--> <!--ID: 1726840632804-->
END%% END%%
@ -672,7 +672,7 @@ unsigned short a;
int b; int b;
``` ```
Back: Because the rank of `unsigned short` is $<$ that of `int`. Back: Because the rank of `unsigned short` is $<$ that of `int`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203475--> <!--ID: 1724762203475-->
END%% END%%
@ -684,7 +684,7 @@ unsigned short a;
signed int b; signed int b;
``` ```
Back: `signed int` or `unsigned int`. Back: `signed int` or `unsigned int`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203479--> <!--ID: 1724762203479-->
END%% END%%
@ -696,7 +696,7 @@ unsigned short a;
signed int b; signed int b;
``` ```
Back: When `signed int` can represent all the values of `unsigned short`. Back: When `signed int` can represent all the values of `unsigned short`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203484--> <!--ID: 1724762203484-->
END%% END%%
@ -708,7 +708,7 @@ unsigned short a;
signed int b; signed int b;
``` ```
Back: When `signed int` cannot represent all the values of `unsigned short`. Back: When `signed int` cannot represent all the values of `unsigned short`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203488--> <!--ID: 1724762203488-->
END%% END%%
@ -720,7 +720,7 @@ unsigned short a;
signed int b; signed int b;
``` ```
Back: N/A. It never is. Back: N/A. It never is.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203492--> <!--ID: 1724762203492-->
END%% END%%
@ -728,7 +728,7 @@ END%%
Basic Basic
Suppose `a` and `b` has signed and unsigned types respectively. When is `a + b` signed? Suppose `a` and `b` has signed and unsigned types respectively. When is `a + b` signed?
Back: When `b`'s type has lower rank and the range of `b` is included in the range of `a`. Back: When `b`'s type has lower rank and the range of `b` is included in the range of `a`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203460--> <!--ID: 1724762203460-->
END%% END%%
@ -736,11 +736,11 @@ END%%
Basic Basic
Suppose `a` and `b` have signed and unsigned types respectively. When is `a + b` unsigned? Suppose `a` and `b` have signed and unsigned types respectively. When is `a + b` unsigned?
Back: When `b`'s type has higher rank or the range of `a` cannot fit the range of `b`. Back: When `b`'s type has higher rank or the range of `a` cannot fit the range of `b`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724762203465--> <!--ID: 1724762203465-->
END%% END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).

View File

@ -39,7 +39,7 @@ END%%
Basic Basic
The integer types are grouped into what two classes? The integer types are grouped into what two classes?
Back: The signed and unsigned integer types. Back: The signed and unsigned integer types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546870212--> <!--ID: 1724546870212-->
END%% END%%
@ -47,7 +47,7 @@ END%%
Basic Basic
The floating point types are grouped into what two classes? The floating point types are grouped into what two classes?
Back: The real and complex floating point types. Back: The real and complex floating point types.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1724546870217--> <!--ID: 1724546870217-->
END%% END%%
@ -267,7 +267,7 @@ END%%
Basic Basic
What are the character types? What are the character types?
Back: `char`, `signed char`, and `unsigned char`. Back: `char`, `signed char`, and `unsigned char`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732622657234--> <!--ID: 1732622657234-->
END%% END%%
@ -275,7 +275,7 @@ END%%
Basic Basic
`char` has the same range, representation, and behavior as what other type? `char` has the same range, representation, and behavior as what other type?
Back: Either `signed char` or `unsigned char`. Back: Either `signed char` or `unsigned char`.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732622657240--> <!--ID: 1732622657240-->
END%% END%%
@ -283,7 +283,7 @@ END%%
Basic Basic
How do you check if `char` has the same representation as a `signed char` or `unsigned char`? How do you check if `char` has the same representation as a `signed char` or `unsigned char`?
Back: Check if `CHAR_MIN` has value `SCHAR_MIN` or `0` respectively. Back: Check if `CHAR_MIN` has value `SCHAR_MIN` or `0` respectively.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732622657243--> <!--ID: 1732622657243-->
END%% END%%
@ -291,7 +291,7 @@ END%%
Basic Basic
Which header defines `CHAR_MIN`? Which header defines `CHAR_MIN`?
Back: `<limits.h>` Back: `<limits.h>`
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1732622657247--> <!--ID: 1732622657247-->
END%% END%%
@ -1418,7 +1418,7 @@ END%%
Basic Basic
What name is given to members of an enumeration? What name is given to members of an enumeration?
Back: An enumeration constant. Back: An enumeration constant.
Reference: “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). Reference: “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
<!--ID: 1730902791672--> <!--ID: 1730902791672-->
END%% END%%
@ -1472,7 +1472,7 @@ END%%
## Bibliography ## Bibliography
* “ISO: Programming Languages - C,” April 12, 2011, [https://port70.net/~nsz/c/c11/n1570.pdf](https://port70.net/~nsz/c/c11/n1570.pdf). * “ISO: Programming Languages - C17,” April 2017, [https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf](https://www.open-std.org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_fdis.pdf).
* Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020). * Jens Gustedt, _Modern C_ (Shelter Island, NY: Manning Publications Co, 2020).
* Raymond, Eric. “The Lost Art of Structure Packing.” Accessed November 4, 2024. [http://www.catb.org/esr/structure-packing/](http://www.catb.org/esr/structure-packing/). * Raymond, Eric. “The Lost Art of Structure Packing.” Accessed November 4, 2024. [http://www.catb.org/esr/structure-packing/](http://www.catb.org/esr/structure-packing/).
* Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994. * Van der Linden, Peter. _Expert C Programming: Deep C Secrets_. Programming Languages / C. Mountain View, Cal.: SunSoft Pr, 1994.