C++ Syntax and Concepts Quiz

C++ Syntax and Concepts Quiz

University

15 Qs

quiz-placeholder

Similar activities

Python dictionary

Python dictionary

University

11 Qs

Testez vos soft skills

Testez vos soft skills

University

18 Qs

Signal and System

Signal and System

University

15 Qs

C Programming

C Programming

University

17 Qs

Economics products and cost

Economics products and cost

University

20 Qs

Economics Quiz on Production Concepts

Economics Quiz on Production Concepts

University

20 Qs

Micro-organismes

Micro-organismes

1st Grade - University

10 Qs

Instruction Set Architecture Quiz

Instruction Set Architecture Quiz

University

10 Qs

C++ Syntax and Concepts Quiz

C++ Syntax and Concepts Quiz

Assessment

Quiz

Others

University

Hard

Created by

MO7MD Waled

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is a correct syntax to output "Hello World" in C++?

print ("Hello World");

cout << "Hello World";

System.out.println("Hello World");

Console.WriteLine("Hello World");

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is used for comments in C++?

/* comment */

// comment

// comment

both // comment or /* comment */

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a correct identifier in C++?

VAR_1234

$var_name

7VARNAME

7var_name

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is used to terminate the function declaration in C++?

;

]

[

:

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which data type is used to create a variable that should store text?

String

string

sting

None

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you create a variable with the floating number 2.8?

byte num=2.8;

int num = 2.8;

num =2.8;

double num=2.8;

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which operator can be used to compare two values?

<>

==

=

><

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?