Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 768565
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T18:12:06+00:00 2026-05-14T18:12:06+00:00

Assume my system as 32 bit machine. Considering this if I use long int

  • 0

Assume my system as 32 bit machine. Considering this if I use long int for n>63 I will get my value as 0. How to solve it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T18:12:07+00:00Added an answer on May 14, 2026 at 6:12 pm

    double is perfectly capable of storing powers of two up to 1023 exactly. Don’t let someone tell you that floating point numbers are somehow always inexact. This is a special case where they aren’t!

    double x = 1.0;
    for (int n = 0; n <= 200; ++n)
    {
        printf("2^%d = %.0f\n", n, x);
        x *= 2.0;
    }
    

    Some output of the program:

    2^0 = 1
    2^1 = 2
    2^2 = 4
    2^3 = 8
    2^4 = 16
    ...
    2^196 = 100433627766186892221372630771322662657637687111424552206336
    2^197 = 200867255532373784442745261542645325315275374222849104412672
    2^198 = 401734511064747568885490523085290650630550748445698208825344
    2^199 = 803469022129495137770981046170581301261101496891396417650688
    2^200 = 1606938044258990275541962092341162602522202993782792835301376
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Assume this much: I'm using a 16.16 fixed point system. System is 32 bit.
I am using PHP 5.3. On my 32-bit system the size of an INT:
Assume following: public class MyFunkyTable : DbObject { // this class will be generated
I can't seem to get past this problem, I've created what I assume to
I am working with a system whereby I can send 1 32 bit int
Lets assume we are talking about 32bit system. PHP doesn't support unsigned INT. It
Assume a system that contains only the basic Perl installation without any extra CPAN
Let's assume that our system can perform actions, and that an action requires some
Assume that I have login to system using PHP + MySQL, then, after I
Assume that you're working a x86 32-bits system. Your task is to implement the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.