C++ Questions and answers

c++ introduction

What is the c++

c++ is computer programming language. it is the most popular language. c++ known as middle level language. c++ is structured language.

Who is the founder of c++

Bjarne Stroustrup is the founder of c++ programming language. He discovered c++ at bell labs in 1985. still c++ is most popular language.

what is the release date of c++

C++ was released in 1985.

What is the level of c++ language

c++ is Both high level and low level language. Hence c++ is middle level language.

what type of language is c++

C++ is object oriented programming language.

In which lab c++ is discovered

c++ discovered at Bell Labs.

what are the appliactions of c++

c++ used to develope desktop applications. c++ used to develope games. c++ used for developing diffrent types of softwares. c++ used for developing complex softwares.

Which companies uses c++

c++ used by big companies for backend development. google,amazon,facebook, spotify,twitter uses c++ for backend development. worlds famous space orgnization Nasa also uses c++.

What are the features of c++

C++ is the most powerful language. It is fast compilable language. c++ handles complex graphics. c++ is object oriented programming language. c++ provides features like classes,functions, inheritance,polymorphism overall it is structured programming language.These are the features of c++.

C++ syntax

How to print output in C++

In c++ programming we use cout keyword for printing output of our code.

How to accept input in c++

c++ provide very simple keyword for accepting input from user. That is cin.

What is the header files in the c++

Every program of c++ starts with header files. header files are predifined libraries of functions. for eg: iostream header file contain Input/output functions like, cout and cin.

which are the most important header files in c++

In c++ there are so many header files for different functions. The most important header files are, iostream.h,conio.h,math.h, string.h,graphic.h These are the header file which are most important to run, c++ program.

What is the data type in c++

In c++ programming we have to specify data type. data type is the name given to specific group of data, like int for intergers data, float for decimal point of data, char for character type of data. data type is the specifications of specific group of data, eg: int a . (int is data type for integers).

which are the data types present in c++

c++ contains integer,float,double,character data types. we write these data types like this, int,float,double,char.

How to add integer data type in c++

In c++ we use int as integer data type. eg: int num=10;

How to add character data type in c++

In c++ we use char keyword to add character datatype.eg: char name;

How to add decimal point data type in c++

In c++ for decimal point data type we use float. eg: float=2.5;

How to add double data type in c++ ?

In c++ we use double for long intergers or floats. Here is how to specify double in c++ program eg: double result;

How to write cout in c++

In c++ we use cout to show output. Here is the exmaple, how to write cout in your c++ code, eg: cout<<"Hello world";

How to write cin in c++

In c++ we use cin for taking input from user. Here is How to write cin keyword in c++ code eg: cin>>number1;

How to write header files in c++

In c++ we have to add header files. here is how to write header files eg: #include < iostream.h >

what is the iostream.h in c++

iostream is the header file in c++. it contains Input and output functions like cout and cin.

what is the conio.h in c++

conio.h is the header file in c++. it is used to add consol input/output functions in c++ code. for example getch() function is the part of conio.h file.

what is the void main() in c++

In c++ we use void main(). Here void is the null data type. main() is the function. Each c++ program starts with main() function. c++ executes only main() function code. it is the main part of C++ code.

what is the void in c++

void is the data type in c++. void is the null data type. void nothing returns.

what is the main() in c++

main() is the function in c++. without main() its not possialble to run c++ code. because execution of program starts from main().

what is the curley brackets in c++

curly brackets {} in c++ code essentail. The code between the brackets {} is called block of code. brackets helps us to orgnize code in the form of blocks.

what is the basic syntax of c++ code

Here is the syntax of c++ code. 1.include header fies, 2.add main() function, 3. use opening curly bracket, 4.start adding body of your code, 5) Then End with closeing curly bracket. eg : #include < iostream.h > void main() { //your code here getch(); }

C++ Functions

What are the types of functions in c++

Their are two types of functions. 1) library functions ,2) userdefined functions.

What is the function in c++

function is a block of code. which perform specific task. is called functions.

Where we use functions in c++

Functions used in big problem. where we have to perform number of task. functions helps us to devide code in small modules. funtions are reusable.

Why we use functions in c++

Functions are useful in c++ because, functions helps use to make small parts of big code, we call that small part as a function or module. Functions makes easy to solve big problems. These functions are reusable. hence functions are useful in c++.

Is it necessary to use functions in c++

No! functions are alternative for efficient coding. if you don't want to use functions, then You can code basic program. The benefits of functions are ,functions gives us flexiblity to write code for big problems. functions devide big programs in small modules.

Comments