x is initialized in compile time when "a+b" haven't been implemented. Ray Devore <[EMAIL PROTECTED]> 写道: --- praveen kumar <[EMAIL PROTECTED]> wrote:
> hai friends > i have a common doubt > plz clarify it > AS > BELOW. > > int a=10, b=20; > static int x= a+b; > > when the above code is compiled it is giving an > error. > > thanks in advance > PRAVEEN > > Don't use all caps, it is considered yelling. Are you using C or C++? What compiler? Ray __________________________________________________________ Park yourself in front of a world of choices in alternative vehicles. Visit the Yahoo! Auto Green Center. http://autos.yahoo.com/green_center/ sky is blue and life is shining --------------------------------- 雅虎免费邮箱3.5G容量,20M附件! [Non-text portions of this message have been removed]
