Welcome to the most active Linux Forum on the web.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


Closed Thread
  Search this Thread
Old 01-12-2010, 08:34 AM   #1
LQ Newbie
Registered: May 2009
Location: kolkata,india
Distribution: fedora
Posts: 6

Rep: Reputation: 0
Is not 'long long' of 8 bytes in gcc?

Both 'long long' and 'double' are 64 bit data types in gcc but
why can't I insert a value greater than 2^31-1 (ie 32bit)
in a long long type variable.

secondly in the following code,

long long v=1000;

the program continues to print negative value of v
even after 2^31-1.Why?
Old 01-12-2010, 08:40 AM   #2
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
This is a duplicate of your REPLY in your other thread. Please keep it in one thread. Duplicate closed

Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Is not 'long long' of 8 bytes in gcc? ishandutta2007 Programming 12 01-12-2010 11:00 PM
LXer: This week at LWN: Long discussions about long names LXer Syndicated Linux News 0 05-19-2009 10:50 PM
Unable to use long long number types? Aziz Programming 4 03-28-2009 05:22 PM
Long standing USB problem with XP & Linux...long cbjhawks Linux - Hardware 4 02-23-2009 08:32 AM
long filename & long directory tree slack66 Slackware 1 09-20-2006 09:56 AM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:08 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration