1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Someone please tell me why the use of ^ sign is not allowed in c?????????

Discussion in 'C' started by ramgates, Jan 29, 2007.

  1. ramgates

    ramgates New Member

    Joined:
    Jan 29, 2007
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    0
    Hai guys I dont know why the use of ^ sign (that is to denote 2*2*2 as 2^3) is not allowed in c, eventough we say c language as a powerfull language?????????????????????????? :confused: :confused:
    Please tell me the reason!!!!!!!!!!!!!!!!!! :eek: :eek:
     
  2. friendsforniraj

    friendsforniraj New Member

    Joined:
    Nov 24, 2006
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    0
    Occupation:
    studying
    hello
    c do allows use of ^ but not for power function
    but this is an operator in c used for xor operations
    you will learn dat in bitwise operations
    and if you want to do the power of a no
    then c has a predefined function in math.h
    named pow(no,power);
    means if u want to do 2*2*2;
    jus do pow(2,3)
     

Share This Page