Fundamentals of Computing - Test Questions with Answers(C-programming) PDF

Title Fundamentals of Computing - Test Questions with Answers(C-programming)
Course Computer Engineering
Institution Pangasinan State University
Pages 2
File Size 37.8 KB
File Type PDF
Total Downloads 112
Total Views 166

Summary

Test questions with answers...


Description

Fundamentals of Computing Test 1: C-programming 1. Over the years, programming languages have evolved from symbolic language, to machine language, to high level language. FALSE 2. The tool used by programmer to convert source program to a mavhine language object module. COMPILER 3. The first step in system development is to create a source program. TRUE 4. Function printf always begins printing at the beginning of a new line. FALSE 5. The purpose of a header file, such as stdio.h is to store a program source code. FALSE 6. Shortcut key for running a program. CTRL+F9 7. The escape sequence \t when used in a printf fromat control string causes the cursor to position to the beginning of the next line on the screen. FALSE 8. A program that prints three lines of output must contain three printf statements. FALSE 9. Definitions can appear anywhere in the body of a function. FALSE 10. All variables must be defined before they are used. TRUE 11. All arguments following the format control string in a printf function must be preceded by an ampersand. FALSE 12. All variables must be given a type when they are defined. TRUE 13. Data will be truncated when the higher data type is converted to lower. TRUE 14. The if else0f can be used instead of switch is we need to make a multiway decision on the basis of the value that is not integral. TRUE 15. It is a compile error to use same constant in two case labels. TRUE 16. The control expression in a loop must be explicitly or implicitly initialized. TRUE 17. To control the loop, we need a condition to determine if processing is needed. TRUE 18. The while statement tests the loop continuation condition after the loop body is performed. FALSE 19. An array can store many different types of values. FALSE 20. It is an error if an initializer contains more initializers than there elements in the array. TRUE 21. Array subscript can be of data type double. TRUE 22. Declaration and definition of an array only tell the compiler the name of the array and the type of each element. FALSE 23. The elements of an arrays are not initialized automatically. You must initialize them if you want them to start with known values. TRUE 24. The first dimension of a two dimensional array is known as the column dimension. FALSE 25. Two different types can be stored in a two dimensional array. FALSE 26. A function receiving an address as an argument must define a pointer parameter to receive address. TRUE 27. Call-by-value should be used whenever the calles function does not need to modify the value of the caller’s original variable. TRUE 28. It is not necessary that the areguments passed to a function should match in number, type and orded with the parameters in the function definition, FALSE 29. A variable that is known only within the function in which it is defined. LOCAL VARIABLE

30. It allows the compiler to check the number, types, and order of the arguments passed to a function. FUNCTION PROTOTYPE 31. A variable of type double can store a value of much greater magnitude and precision than float can store. TRUE 32. The address operator can be applied to constant, to expressions and to variables. TRUE 33. This contains the function prototypes for math library functions. 34. Pointers can be defined to point objects of any type. TRUE 35. A pointer maybe initialized to zero, null or an address. TRUE...


Similar Free PDFs