From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,726e9bcf769df489,start X-Google-Attributes: gid103376,public From: jsanchor@cs5.dasd.honeywell.com Subject: Integer Division Date: 1998/08/05 Message-ID: <6qa43u$eip$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 378221612 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Wed Aug 05 17:17:50 1998 GMT Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.04 [en] (X11; U; SunOS 5.5.1 sun4u) Date: 1998-08-05T00:00:00+00:00 List-Id: Hi guys, I have a question. It is so simple that it seems stupid. I was doing a simple arithmetic operation 10/3. Now, I want the INTEGER division to return the next whole number (i.e. 4). I know in floating_point type they have an attribute called 'Ceiling. What about integer types? Currently, I am doing a division operation B := A/3, & then a 'rem' operation if A rem 3 /= 0 then B = B + 1; Is there a nicer method? Thank you in advance. Sincerely, Jay S. -----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum