Q1_Solutions_Fall_2009_Practice_Test_3

Q1_Solutions_Fall_20 - Problem 1 Short Answer A Which tool turns text into binary object files a editor b compiler c Outlook Express d linker e

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Problem 1: Short Answer A) Which tool turns text into binary object files? a) editor b) compiler c) Outlook Express d) linker e) Visual Studio B) Which tool assembles object files and libraries into an executable program? a) editor b) compiler c) Outlook Express d) linker e) Visual Studio C) Describe in two sentences or less what the following line of C code means: typedef int (*coolFunc) (char,int*); Creates a function pointer that returns an int and takes in a char and int * //This is not going to be in our test, we have not gone over this D) Given the code: char *str = "abcdefg"; what values are returned by sizeof(str) + strlen(str) ? a) 8 b) 11 //4+7, str is a pointer:4, strlen does not count the '\0' c) 12 d) 14 e) 15 e) 16 f) none of the above E) Which of the following is equivalent to free(ptr);? a) malloc(NULL); b) calloc(ptr); c) realloc(NULL, ptr); d) calloc(ptr, 0); e) realloc(ptr, 0); F) Circle the code segments below that will compile and run correctly (no errors or warnings) (more than one may be correct)
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/15/2011 for the course CS 1372 taught by Professor Smith during the Spring '10 term at Central GA Tech.

Page1 / 3

Q1_Solutions_Fall_20 - Problem 1 Short Answer A Which tool turns text into binary object files a editor b compiler c Outlook Express d linker e

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online