Ask Questions & Get Answers at ibibo sawaal

Ask your Question in Kanpur

Character(s) remaining:  160
 
Ask now

What does it mean for a function parameter to be const? What do the two const's in int f(const * const p) mean?  

Asked in Kanpur at 2:08 PM on October 08, 2008

Tags: function, parameter, const, int

! This question is closed
Report abuse
keshav
keshav
Profile | Q&A

Related Search

 

how can we declare constant variables in c?

const. You do that by appending const after its parameter list. For example:class Personpublic: int getAge const return age; //const member functionprivate: int age;;Note that const member functions modifiable, as shown in Listing B.Const member functionsA class objects state consists of the values of its nonstatic data members. A member function that doesnt change its objects state should be declared

Posted in Computers & Technology by monal rajput at 12:06 AM on September 05, 2008

What is passing by reference?

-value-and-passing-by-reference/?S =B20000...Passing by by reference refers to a method of passing the address of an argument in the calling function to a corresponding parameter in the called function. C onlyIn C, the corresponding parameter in the called function must be declared as a pointer type. C only In C, the corresponding parameter can be declared as any reference type, not just a pointer type.In this way, the value

Posted in Computers & Technology by Abhi at 4:33 PM on September 30, 2008

what is function prototype?

The function prototype can be defined as-A declaration of the types of parameters expected by a function and of the type of the result it returns. ANSI C requires function prototypes for all functions you define.A declaration of a function to the compiler indicating what types of parameters are passed to it and what value is returned. The compiler can then report an error if a function within

Posted in Computers & Technology by neha sandhu at 11:15 PM on October 06, 2008
Tags function

What does it mean for a function parameter to be const? What do the two consts inint fconst const pmean?

Inint fconst const pthe first of the two consts is perfectly appropriate and quite useful; many functions declare parameters which are pointers to const data, and doing so documents and tends an ordinary non-pointer parameter as const:int f2const int xThis says that nowhere in the body of f2 will the function assign a different value to x. Compilers should try to enforce this promise, too

Posted in Kanpur by keshav at 8:02 PM on October 08, 2008

i want to repair my pc as a primary repair if anobody knows the dos commands thats execute in repairing so plz

.Windows NT/2000: The Unicode version of this function, CreateProcessW, willfail if this parameter is a const string.The lpCommandLine parameter can be NULL. In that case, the function uses thestring pointed const string.The lpCommandLine parameter can be NULL. In that case, the function uses thestring pointed to by lpApplicationName as the command line.If both lpApplicationName and lpCommandLine are non

Posted in Computers & Technology by Anil Kumar at 2:58 PM on July 31, 2008

what is Pointers and how to declared inline fuction

to your member functions just like any other parameter, but it is not given explicitly in the member functions prototype. You cannot use pointers to member functions to store the address of a static of the object it is called on behalf of, not the static type of the member function pointer: include <iostream>class Basepublic:virtual void WhoAmI const;typedef void Base::WhoPtr const;;class Derived

Posted in Computers & Technology by shepherd at 1:47 PM on May 08, 2008

explain with example virtual function supporting run-time polymorphism?

in certain contexts.source site: http://en.wikibooks.org/wiki/C 2B2BProgramming/Classes/Pol ymorphism...HelloC handle these multiple versions of a function using virtual function.Based on the parameters beingA function that is defined in a base class but overridden by the derived class is called a virtual function. To create virtual functions precede the function declaration in the base class

Posted in Computers & Technology by bwd at 2:50 AM on September 06, 2008

can scrollbars be added in a visual basic form?

, the horizontal scroll bar is disabled.The parameters for the SendMessage function are as follows:SendMessagehWnd, LBSETHORIZONTALEXTENT, wParam, lParam&hWnd - Handle to the list boxwParam - Specifies box is large as or larger than this value, the horizontal scroll bar is disabled.The parameters for the SendMessage function are as follows:SendMessagehWnd, LBSETHORIZONTALEXTENT, wParam, l

Posted in Computers & Technology by SANJU at 4:06 PM on June 14, 2008
Tags

Give example of inheritence in C?

of member functions:vecRange::vecRan geint lb,int ub //constructor takes two parameters : vectorub-lb1 //invoke base class vectors constructor lwb=lb; upb=ub; //set vecRanges bounds int& vec of Base, and inherit protected area of Base, but cant inherit private area of Base.While inheriting from a Base, Derived class s public functions wont get access to Bases private area. Derived class can

Posted in Computers & Technology by bwd at 4:02 AM on September 06, 2008

What is the difference between call by value, call by reference, call by address?

values to its parameters, only the local copy is assigned -- that is, anything passed into a function call is unchanged in the callers scope when the function returns.In call-by-reference evaluation, a to the corresponding variable in the function usually by capture-avoiding substitution or by copying the value into a new memory region. If the function or procedure is able to assign values to its parameters, only

Posted in Computers & Technology by Radha at 11:28 PM on June 28, 2008

How to work in a maximized designing window in VB.net?

of this class type and call the function using the class variable.Using the code It will return current resolution parameters. It can make a form FULLSCREEN ... IPStudents.Info - Its all about creativity and ideas. Author : Yash Bharadwaj and Chander Prakash Copyright : Free to use.Dont remove this Sticker.Usage: Just call function fullscreen with form name as parameter.It can detect client resolution

Posted in Computers & Technology by Debabrata at 12:50 PM on September 22, 2008

how to store image in databasesql server 2000?

Command"INSERT INTO ImageStoreimgtitle,imgtype,imgdata VALUES imgtitle, imgtype,imgdata ", connection ;SqlParameter paramTitle = new SqlParameter"imgtitle", SqlDbType.VarChar,50 ;paramTitle.Value = imgtitle;command.Parameters.Add paramTitle;SqlParameter paramData = new SqlParameter "imgdata", SqlDbType.Image ;paramData.Value = imgdata;command.Parameters.Add paramData ;SqlParameter paramType = new SqlParameter...

Posted in Computers & Technology by Saurabh at 6:17 AM on September 19, 2008

What is Constructor?

... ; If that doesnt work, e.g., if there isnt an appropriate default parameter that combines the two constructors, sometimes you can share their common code in a private init member function: class Foo publicHello..In a C class definition, a member function with thesame name as the class is a constructor. This is a function whichis called automatically whenever an instance of the class is created

Posted in Computers & Technology by bwd at 5:27 PM on September 06, 2008

what is functions in c?

keyword void to indicate that a function takes no parameters especially in C and/or does not return any value. Note that C/C functions can have side-effects, including modifying any variables whose addresses are passed as parameters i.e. "passed by reference". Examples: void function1void / some code / The function does not return a value and has to be called as a stand-alone function, e

Posted in Computers & Technology by neha sandhu at 11:17 PM on October 06, 2008
Tags functions
Categories
sawaal signature