Question

Please answer True or False 1.) SLOC – source lines of code is an effective measure...

Please answer True or False

1.) SLOC – source lines of code is an effective measure of a programmers performance.

2.) In C, for variables declared as static within a function   their values cannot be changed later, after the point of their declaration.

3.) In C, a function can be accessed from outside the file where it is defined.

4.) With the const qualifier, we can protect the value pointed to by a pointer from being modified by the called function. Similarly, we can protect the pointer itself from being re-directed by also using theconst qualifier.

5.) In C, the ternary operator can always be replaced with a sequence of if statements

6.) Dynamic linking is usually more efficient in terms of both space and  time (at  execution  time) than static linking.

7.) When compared with static linking, dynamic linking makes it easier to extend a large program to handle new functionalities.

8.) The functions printf and scanf are two important input/output functions, but they are not keywords in C

9.) In C, pointers and arrays are very closely related. Thus, any operation we can perform with a pointer can equally be performed using an array.

10.) Counter-controlled repetition is typically used for indefinite repetition while sentinel-controlled repetition is typically used for definite repetition

Homework Answers

Answer #1

1) True .

SLOC gives the size of the program by counting the number of lines in text of source code of the program. It also gives an estimate of productivity of the program once the software is ready. It is used to measure complexity, predict the amount of effort and time needed to develop a program.

2) False .

A variable declared as static inside a function holds the value till the end of the entire program, not till the end of the function block. The value of the static function can be changed after the declaration of the variable as static.

3) True .

Function are visible within all files not only the file in which it is defined. There are mechanisms for accessing.

4) False .

The value of the object pointed using pointer cannot be changed . But , We can change the pointer to point to any other integer variable.

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions