
C-Volution (Hard)

Quiz
•
Information Technology (IT)
•
University
•
Hard
Sujal Bhagat
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What is the output of the following code?
#include
1 1 2 1 2 3 1 2 3 4 1 2 3 4 5
1 2 2 3 3 3 4 4 4 4 5 5 5 5 5
1 2 3 4 5 1 2 3 4 1 2 3 1 2 1
1 2 3 4 5 2 3 4 5 3 4 5 4 5 5
2.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What is the output of the following code?
#include
***** **** *** ** *
* ** *** **** *****
***** **** *** ** *
* ** *** **** *****
3.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What is the error in the following code?
#include
Missing #include directive.
Dereferencing an uninitialized pointer.
Incorrect format specifier in printf().
No error.
4.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What does the following code snippet do? #define SQUARE(x) x * x
Defines a function named SQUARE.
Defines a macro named SQUARE.
Declares a variable named SQUARE.
Includes a header file named SQUARE.
5.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What is the output of the following code?
#include
* * * * * * *
**** **** **** ****
* * * *
Nothing will be printed.
6.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What is the correct way to dynamically allocate memory for an array of 10 integers?
int *arr = malloc(10 * sizeof(int));
int *arr = calloc(10, sizeof(int));
int *arr = new int[10];
Both (a) and (b)
7.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
What is the output of the following code?
#include
1 2 3 4 5
1 2 3 4 5 6
1 2 3 4
Infinite loop
Create a free account and access millions of resources
Similar Resources on Wayground
5 questions
C# quiz

Quiz
•
12th Grade - University
10 questions
C Programming Quiz

Quiz
•
University
15 questions
Web Application - PHP Repetition

Quiz
•
University
10 questions
Quiz CG - Code V2

Quiz
•
University
10 questions
Operasi Input & Output C++

Quiz
•
University
15 questions
BYTS ASSESSMENT

Quiz
•
University
15 questions
Python Loop

Quiz
•
University
15 questions
CMDP2063 Unix and C Programming (Revision)

Quiz
•
University
Popular Resources on Wayground
18 questions
Writing Launch Day 1

Lesson
•
3rd Grade
11 questions
Hallway & Bathroom Expectations

Quiz
•
6th - 8th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade