C Programming Quiz on Variables and Constants

C Programming Quiz on Variables and Constants

Professional Development

19 Qs

quiz-placeholder

Similar activities

Python -  Fundamentals I

Python - Fundamentals I

Professional Development

17 Qs

Stats+Python ISA Test - Quiz 2

Stats+Python ISA Test - Quiz 2

University - Professional Development

20 Qs

4IR workshop - APE&OE

4IR workshop - APE&OE

Professional Development

15 Qs

Basic Otomotif

Basic Otomotif

Professional Development

15 Qs

Fundamentos de la Programación

Fundamentos de la Programación

Professional Development

24 Qs

Conversión y Condicionales

Conversión y Condicionales

Professional Development

16 Qs

Revisão Aula 01 - Introdução à Microcontroladores

Revisão Aula 01 - Introdução à Microcontroladores

Professional Development

17 Qs

C# TOPIC NEW-2

C# TOPIC NEW-2

Professional Development

15 Qs

C Programming Quiz on Variables and Constants

C Programming Quiz on Variables and Constants

Assessment

Quiz

Instructional Technology

Professional Development

Easy

Created by

A Lakshman

Used 1+ times

FREE Resource

19 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct syntax to declare an integer variable?

integer x;

x:int;

var x:int;

int x;

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How many bytes of memory are allocated for a float variable?

4 bytes

2 bytes

8 bytes

1 byte

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a valid identifier?

1stVariable

variable-name

variable name

variable_name

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the maximum length of an identifier in C?

32 characters

64 characters

128 characters

256 characters

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a keyword in C?

variable

function

return

identifier

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the 'const' keyword in C?

To create a function

To allocate memory

To declare a variable

To define a constant

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is NOT a valid constant type in C?

Octal constant

String constant

Floating constant

Hexadecimal constant

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?