[20232] CSC126: Quick Exercise 2-2

[20232] CSC126: Quick Exercise 2-2

University

7 Qs

quiz-placeholder

Similar activities

Introduction to Big Data Analytics

Introduction to Big Data Analytics

University

8 Qs

CodeMonkey for B.Ed IT

CodeMonkey for B.Ed IT

University

10 Qs

JRB2 Quiz 4

JRB2 Quiz 4

University

10 Qs

JAVA QUIZ-1

JAVA QUIZ-1

University

10 Qs

QUIZ SIA 2 - AUDITING COMPUTER

QUIZ SIA 2 - AUDITING COMPUTER

University

10 Qs

Python Quiz 1.4

Python Quiz 1.4

University

12 Qs

BB

BB

University

10 Qs

[20232] CSC126: Quick Exercise 2-2

[20232] CSC126: Quick Exercise 2-2

Assessment

Quiz

Computers

University

Practice Problem

Easy

Created by

ZALIKHA ZULKIFLI

Used 42+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

7 questions

Show all answers

1.

OPEN ENDED QUESTION

5 mins • 2 pts

Write a C++ declaration statement for each of the following questions:

Declare three variables as integer. Assign the first variable to 10.

Evaluate responses using AI:

OFF

Answer explanation

int num1 = 10, num2, num3;

OR

int num1 = 10;

int num2;

int num3;

2.

OPEN ENDED QUESTION

5 mins • 1 pt

Write a C++ declaration statement for each of the following questions:

Declare a constant variable named RATE as float and assign it to 0.125.

Evaluate responses using AI:

OFF

Answer explanation

const float RATE = 0.125;

3.

OPEN ENDED QUESTION

5 mins • 1 pt

Write a C++ declaration statement for each of the following questions:

Declare a floating-point variable named initial with value 100.

Evaluate responses using AI:

OFF

Answer explanation

float initial = 100;

4.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Given the following declaration:

int w = 5, x = 7, y = 3, z = 12;

What is the result of the following expression?

w * x % y + z

14

17

21

22

5.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

What is the result of the following expression if data type of y is int?

y = 4 + (3 * (8 + 6) – 3) / 2

17.5

23.5

23

29

6.

OPEN ENDED QUESTION

5 mins • 1 pt

Evaluate the following expression:

x = 42 % 5 + 7 – (2 + 8) / 3;

Evaluate responses using AI:

OFF

Answer explanation

6

7.

OPEN ENDED QUESTION

5 mins • 1 pt

Evaluate the following expression:

y = 13.0 + 9 / 2.0

Evaluate responses using AI:

OFF

Answer explanation

17.5

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?