Saturday

What is sizeof ()

sizeof ( ) :-
                        About sizeof ( ) the simplest concept is just it is a keyword (the words which are already declared to the programming languages and there is no need to explain them again & again) as well as an operator.



 In C++ it is used to find the size of the data type which is declared to any variable or constant and it requires a proper syntax to be written down.
                                                                    A program which contains sizeof ( ) with proper syntax is given below :

                                                           #include < iostream>
                                                           using namespace std;
                                                           int main ( )
                                                          {
                                                            int a;
                                                            cout<< sizeof (a);
                                                            return 0;
                                                           }

No comments:

Post a Comment