Thread: Signed and unsigned

  1. #1
    Registered User
    Join Date
    Aug 2011
    Posts
    102

    Signed and unsigned

    What is the different between a signed decimal integer and unsigned decimal integer. I don't understand this (signed and unsigned) well since i'm new to it. Thanks

  2. #2
    and the Hat of Guessing tabstop's Avatar
    Join Date
    Nov 2007
    Posts
    14,336
    A signed integer has a sign attached to it (+, -, or Sagittarius); while an unsigned integer does not (and is always assumed positive).

  3. #3
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by ncode View Post
    What is the different between a signed decimal integer and unsigned decimal integer. I don't understand this (signed and unsigned) well since i'm new to it. Thanks
    Signed integers can store negative numbers, unsigned cannot.
    Also unsigned integers have twice the positive number range of signed integers.

    The ranges for a 32 bit integer are...
    Signed : -2,147,483,648 to 2,147,483,647
    Unsigned: 0 to 4,294,967,295

  4. #4
    Registered User
    Join Date
    Aug 2011
    Posts
    102
    ok get it. Thank you guys

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Signed and unsigned
    By alyeska in forum C++ Programming
    Replies: 5
    Last Post: 09-18-2007, 12:27 PM
  2. signed or unsigned?
    By ulillillia in forum C Programming
    Replies: 7
    Last Post: 05-08-2007, 01:06 AM
  3. Signed vs Unsigned int
    By osyrez in forum C++ Programming
    Replies: 18
    Last Post: 08-17-2006, 07:38 AM
  4. signed/ unsigned what!!
    By the bassinvader in forum C Programming
    Replies: 3
    Last Post: 07-27-2006, 01:46 PM
  5. signed/unsigned int
    By X PaYnE X in forum C Programming
    Replies: 3
    Last Post: 06-10-2004, 10:58 AM