COMPUTING 1 TRUE/FALSE

Ace your homework & exams now with Quizwiz!

'\n' is two characters

F

A boolean expression may evaluate to more than 2 values

F

A break statement in a switch stops your program

F

A function may return more than one item

F

A stub is a function that is completely defined and well tested

F

A void function can be used in an assignment

F

A void function can return any value

F

All nested if else statements can be converted into switch statements

F

Arrays can be returned from a function

F

Every line in a program should have a comment

F

FOPEN_MAX is a macro defined in stdlib.h

F

If x has the value of 3, y has the value of -2,and w is 10 is the following condition is true or false? if(x<2 && w<y)

F

If you use the const modifier in a function declaration, you do not include it in the function definition

F

In an enumerated data type, different constants may not have the same value

F

It is illegal to call other functions from inside a function definition

F

It is illegal to make function calls inside a switch statement

F

Loops are used when we used our program to make a choice between two or more things

F

Scanf can read all floating point values, floats, doubles, and long doubles using the %f format specifier

F

The break statement causes all loops to exit

F

The fgets function will stop reading in characters if it encounters any whitespace character or the end of file and makes sure that you cannot read more characters than indicated by the max character

F

The following function declaration garantees the values in the array argument are not changed void function1(int array[], int numElements);

F

The formatting options that were discussed for printf do not work for printf

F

The indexed variables(elements) of an array must be integers

F

The integer 0 is considered true

F

The locations of the various indexed variables in an array can be spread out all over the memory

F

The opposite of (x>3 && x<10) is (x<3&& x>10)

F

The opposite of less than is greater than

F

The parameter names are mandatory in the function header

F

The parameters listed in the function declaration are considered global variables

F

The types of parameters are optional in the function declaration

F

Variables names may begin with a number

F

You may have as many files open at once as you like

F

You may not have more than one file open at any one time

F

pow(2,3) is the same as pow(3,2)

F

A function may return a value that can be interpreted as a boolean value for use in it statements or loop conditions

T

A function that passes the address of a variable as a parameter is allowed to make changes to the argument through the dereference operator

T

A semicolon by itself is a valid C statement

T

After following code fragment, x has the value of 3 int x=3

T

All switch statements can be converted into nested if else statements

T

Arrays can be passed by functions

T

FILE pointers may be passed to a function

T

Function naming rules are the same as variable naming rules

T

Functions can return at most one value

T

Functions may have multiple return statements

T

If a function is expecting a pass by reference style parameter by accepting a pointer, you can pass the address of an indexed variable(element) from an array of the same base type to that function

T

In a function mimicing pass-by-reference parameters, the values of the actual arguments passed to the function are addresses

T

It is a legal to declare more than one variable in a single statement

T

It is acceptable to have both normal variable and pointer variable parameters in the same function declaration

T

It is possible to have a function that takes no arguments by having its only parameter be void

T

Since the type FILE as an opaque object type and we only in interact with it through pointers and functions, we should never dereference a FILE pointer

T

The body of a do while loop always executes at least once

T

The body of a while loop may never execute

T

The dereference operator * is a unary operator meaning it only has one operand

T

The following array declaration is legal double scores[]= {0.1,0.2,0.3};

T

The following function will work with any size integer array void function1(int array[], int numElements);

T

The following is legal in a void function: return;

T

The function gets is designed to read a c-string from standard input but is considered unsafe and should not be used because you do not list the buffer size in the argument list

T

Variables that are declared outside of any function body or parameter list are considered to global

T

When you have a function that expects an array, it should also expect the size of the array or the number of indexed variables(elements) with valid data

T

You must use a field width specifier in each format specifier that you want output in a certain field width

T


Related study sets

Funciones lineales y cuadráticas

View Set

Anatomy and Physiology Ch. 2 (Exam 1)

View Set

personal financial literacy: "Spending"

View Set

Indigenous Law IND - CHAPTER 1 - FILL IN

View Set

Conditions Occurring after Delivery

View Set

Lab 1: Spinal Cord and Spinal Nerves

View Set

Words Which Indicate A Past Tense {Passe Compose vs Imparfait}

View Set

Business Law: Nature of Contracts

View Set

Chapter 7 - Developing a Personal Fitness Plan

View Set