delorie.com/archives/browse.cgi | search |
Date: | Sat, 05 May 2001 18:00:05 +0300 |
From: | "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il> |
Sender: | halo1 AT zahav DOT net DOT il |
To: | djgpp AT delorie DOT com |
Message-Id: | <2110-Sat05May2001180005+0300-eliz@is.elta.co.il> |
X-Mailer: | Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.9 |
In-reply-to: | <9d0a3d$jpu4@OM9.omantel.net.om> (alhabsiNOSPAM@squ.edu.om) |
Subject: | Re: How to multiply two 32-bit integers? |
References: | <9d0a3d$jpu4 AT OM9 DOT omantel DOT net DOT om> |
Reply-To: | djgpp AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | djgpp AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
> From: "alhabsi" <alhabsiNOSPAM AT squ DOT edu DOT om> > Newsgroups: comp.os.msdos.djgpp > Date: Sat, 5 May 2001 11:29:12 +0400 > > I would like to multiply two 32-bit ints X and Y and store the 64-bit result > in two ints M and L where M holds the most significant 32 bits. Can anymone > please tell me how? DJGPP supports a `long long' data type, which is a 64-bit integral type. So something like this should do: long long i, j, k; k = i * j;
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |