General Computer Programming Quiz

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Squiva
S
Squiva
Community Contributor
Quizzes Created: 1 | Total Attempts: 9,628
| Attempts: 9,628 | Questions: 10
Please wait...
Question 1 / 10
0 %
0/100
Score 0/100
1. What does HTML stand for?

Explanation

HTML stands for Hyper Text Markup Language. It is a standard markup language used for creating and structuring the content on web pages. HTML uses tags to define elements such as headings, paragraphs, images, links, and more. These tags provide a structure and format to the content, allowing web browsers to interpret and display the information correctly. HTML is the foundation of web development and is essential for creating and designing websites.

Submit
Please wait...
About This Quiz
General Computer Programming Quiz - Quiz

There different types of programming languages in use today and we have been able to cover each of the major ones in depth. Do you feel like you... see moreunderstood them all, when and how to apply them? In this quiz you will get to review all you know about Java, , and C++. Give it a shot and be sure to keep revising! see less

2. <h1>Text</h1> is the correct way of making a header in HTML.

Explanation

In HTML, the

tag is used to create a header, and it is the correct way to make a header in HTML. The

tag represents the highest level of heading and is typically used for main headings on a webpage. It is important to use the appropriate HTML tags to structure and format the content correctly, and in this case, using the

tag for a header is the correct approach.

Submit
3. Which of the following is the correct way to use the standard namespace in C++?

Explanation

The correct way to use the standard namespace in C++ is by using the statement "using namespace std;". This statement allows you to access all the standard library functions and objects without having to specify the "std::" prefix every time.

Submit
4. Which of the following is the correct way of making a string in Java?

Explanation

The correct way of making a string in Java is by using double quotation marks. Therefore, the correct answer is "String text = "text";".

Submit
5. Does the following C++ script have errors? #include "stdafx.h" #include <iostream> using namespace std; int main() {          cout<<"Hello world"<<endl          return 0; }

Explanation

The given C++ script has errors because there is a missing semicolon (;) after the cout statement.

Submit
6. Is this how you import something in C++? #include <string>

Explanation

In C++, the #include directive is used to import libraries or header files, and <string> is a standard C++ header file that provides functions and classes for working with strings. So, #include <string> is used to include the functionality related to strings in your C++ program.

Submit
7. Is this the correct way to make an object in Java? Class class = new Class();

Explanation

In Java, "Class" is a reserved keyword used for reflection to obtain metadata about classes at runtime. Therefore, naming a variable "class" may lead to confusion. A correct way to instantiate an object of a class named "Class" would be: 

Class className = new Class();

Submit
8. In Java, a method is a container that holds classes.

Explanation

In Java, a method is not a container that holds classes. A method is a block of code that performs a specific task and is defined within a class. It is used to encapsulate a set of instructions that can be called and executed when needed. Classes, on the other hand, are used to define objects and their properties and behaviors. Therefore, the statement that a method is a container that holds classes is incorrect.

Submit
9. Is it less bytes to use:       long l = 100; then:       int i = 10;

Explanation

The given answer "No" is correct because both variables, long and int, occupy the same amount of memory in Java. The difference lies in the range of values they can hold. A long variable can store larger values than an int variable, but it does not necessarily use more memory. In this case, both variables are assigned small values, so they would occupy the same number of bytes.

Submit
10. Is this HTML code correct? <html> <head> <title>Title</title> </head> <h1>Header</h1> <p>Paragraph</p> </html>

Explanation

The HTML code is not correct because the

and

elements should be placed inside the

element, not directly inside the element.
Submit
View My Results

Quiz Review Timeline (Updated): Apr 1, 2024 +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Apr 01, 2024
    Quiz Edited by
    ProProfs Editorial Team
  • Nov 04, 2013
    Quiz Created by
    Squiva
Cancel
  • All
    All (10)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
What does HTML stand for?
<h1>Text</h1> is the correct way of making a header in...
Which of the following is the correct way to use the standard...
Which of the following is the correct way of making a string in Java?
Does the following C++ script have errors? ...
Is this how you import something in C++? #include <string>
Is this the correct way to make an object in Java? ...
In Java, a method is a container that holds classes.
Is it less bytes to use: ...
Is this HTML code correct? ...
Alert!

Advertisement