C++ Basics (1)

C++ Basics (1)

University

12 Qs

quiz-placeholder

Similar activities

OM_SBENT3C_Q2

OM_SBENT3C_Q2

University - Professional Development

15 Qs

Hands-on Modul 3

Hands-on Modul 3

University

10 Qs

Visual Basic 2010

Visual Basic 2010

8th Grade - University

10 Qs

CS100||MsWord

CS100||MsWord

University

10 Qs

Types of Mass Media

Types of Mass Media

10th Grade - Professional Development

11 Qs

Website Usability and UX

Website Usability and UX

University

10 Qs

2024 - Struktur Data Quiz 1

2024 - Struktur Data Quiz 1

University

10 Qs

Python Week 1 & 2

Python Week 1 & 2

University

10 Qs

C++ Basics (1)

C++ Basics (1)

Assessment

Quiz

Computers

University

Practice Problem

Medium

Created by

Long Trần

Used 2+ times

FREE Resource

AI

Enhance your content in a minute

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

12 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is a variable in C++?

A keyword that holds a constant value

A memory location that stores a value and can change during program execution

A function that performs a task

A literal that cannot be modified

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a valid way to declare a constant in C++?

int const PI = 3.14;

constant int PI = 3.14;

const int PI = 3.14;

double PI = 3.14;

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is an integer data type in C++?

float

char

int

bool

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of the following code? bool x = true; cout in a C++ program?

To include standard input/output functions

To define constants

To declare variables

To create a new library

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the value of x after the following code? int x = 5; x += 3;

5

8

3

10

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to read input from the console in C++?

cin >> variable;

get(input);

input(variable);

scanf("%d", &variable);

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following symbols is used for comments that span multiple lines in C++?

//

/* */

#

{}

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?

Discover more resources for Computers