M2 CSE240

0.0(0)
studied byStudied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/14

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 6:34 PM on 2/6/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai

No analytics yet

Send a link to your students to track their progress

15 Terms

1
New cards

Which of the following statements are correct if a language is strongly typed. Select all that apply.

Type errors are always reported and each name in a program has a single type associated with it.

2
New cards

Which of the following languages is most likely to report a compilation error for the following snippet of code?

int i = 3;
double n, j = 3.0;
n = i + j;

Java

3
New cards

Converting an integer value 5 to a float number 5.0 takes

At least one important machine instruction to perform conversion between data binary formats.

4
New cards

Type checking happens during compilation phase. It reinforces which of the following structural layers?

Contextual

5
New cards

In the C-Style input function scanf(“%d”, &i), what does the character “&” mean?

scanf takes the address of an variable as its parameter.

6
New cards

A data type is defined by (Select all answers that apply)

the operations allowed and the values allowed.

7
New cards

The imperative programming paradigm is popular and is a part of object-oriented computing paradigm, because it ____ (Select all answers that apply).

matches the common culture of doing things by following the step-wise instructions and is based on computer organization and thus is efficient to execute on hardware.

8
New cards

Where is the main() function located in a C++ program?

outside any class

9
New cards

In C++, what function can be used for inputting a string containing spaces? 

cin.getline(...);

10
New cards

Which of the following types is a C++ type, but NOT a C type?

bool

11
New cards

What is NOT the purpose (functionality) of the forward declaration (prototype)?

to allow a function to return different types of values

12
New cards

In the memory hierarchy of a computer system, which type of memory is the fastest one? 

Registers

13
New cards

Which of the following C assignment statements (assign a value to a variable at the semantic level) will NOT cause a compilation issue?

Assume the array has been declared as: char a[5];

a[0] = 'h'; 

14
New cards

Which of the following C declarations (contextual level) will cause a compilation issue?

int d[] = {12.24, 47.13};

15
New cards

iven a declaration:  char a[] = "Hello World"; What is the size (in bytes) of the array a[]?

12