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

C-BASICS

Quiz
•
Computers
•
University
•
Hard
JENEFA NAVEEN
Used 3+ times
FREE Resource
25 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
printf("Hello World");
System.out.printline("Hello World");
Console.WriteLine("Hello World");
cout << "Hello World";
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a correct way to declare a integer variable in C?
int x;
String x;
float x;
boolean x;
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following C code snippet?
int x = 5;
int y = 3;
printf("%d", x + y);
8
53
15
35
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a correct way to write a for loop in C?
for(int i = 0; i < 10; i++)
for i = 0; i < 10; i++
for i = 0; i < 10
for(int i = 0; i < 10
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct way to define a function in C?
void functionName() {}
functionName() {}
def functionName() {}
function functionName() {}
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which data type is used to store decimal numbers in C?
int
char
float
double
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct way to compare two variables in C?
x == y
x = y
x === y
x != y
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
Code-A-Vita

Quiz
•
University
20 questions
Python Programming - Test 1

Quiz
•
University - Professi...
20 questions
C - Structures

Quiz
•
University
25 questions
GNIDOC ROUND 1

Quiz
•
University
30 questions
python

Quiz
•
University
20 questions
Python

Quiz
•
University
20 questions
CodeHS - Intro to Python - Basics and Console Interaction

Quiz
•
9th Grade - Professio...
30 questions
BUG@MASTER

Quiz
•
University
Popular Resources on Wayground
25 questions
Equations of Circles

Quiz
•
10th - 11th Grade
30 questions
Week 5 Memory Builder 1 (Multiplication and Division Facts)

Quiz
•
9th Grade
33 questions
Unit 3 Summative - Summer School: Immune System

Quiz
•
10th Grade
10 questions
Writing and Identifying Ratios Practice

Quiz
•
5th - 6th Grade
36 questions
Prime and Composite Numbers

Quiz
•
5th Grade
14 questions
Exterior and Interior angles of Polygons

Quiz
•
8th Grade
37 questions
Camp Re-cap Week 1 (no regression)

Quiz
•
9th - 12th Grade
46 questions
Biology Semester 1 Review

Quiz
•
10th Grade