Results 1 to 3 of 3

Math Help - longhand div =/

  1. #1
    Member
    Joined
    Sep 2008
    Posts
    76

    longhand div =/

    I was wondering if you guys know a way to find the first digit of a number.I know that modulus gets you the last digit of a number,

    for instance 456%10 = 6 in remainder

    but how do you find the first digit?
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Like a stone-audioslave ADARSH's Avatar
    Joined
    Aug 2008
    From
    India
    Posts
    726
    Thanks
    2
    Quote Originally Posted by NidhiS View Post
    I was wondering if you guys know a way to find the first digit of a number.I know that modulus gets you the last digit of a number,

    for instance 456%10 = 6 in remainder

    but how do you find the first digit?

    This is a childish answer not always useful ( in fact rarely)

    If the number of digits= n

    Then [\frac{Number  }{10^{n-1}}]

    Where "[ ]" stands for greatest integer function
    Follow Math Help Forum on Facebook and Google+

  3. #3
    MHF Contributor
    Prove It's Avatar
    Joined
    Aug 2008
    Posts
    11,553
    Thanks
    1419
    Quote Originally Posted by NidhiS View Post
    I was wondering if you guys know a way to find the first digit of a number.I know that modulus gets you the last digit of a number,

    for instance 456%10 = 6 in remainder

    but how do you find the first digit?
    Why not just divide the first digit(s) by 10?
    Follow Math Help Forum on Facebook and Google+

Search Tags


/mathhelpforum @mathhelpforum