• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: division by zero not an error for cc?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: division by zero not an error for cc?


  • Subject: Re: division by zero not an error for cc?
  • From: Dan White <email@hidden>
  • Date: Thu, 20 Sep 2001 10:04:37 -0400

At 4:37 PM -0700 9/19/01, Boz Jennings wrote:
>Hi all,
>
>Why does the following not give me a division by zero error?
>
>>int main(void) {
>> result = 1 / 0;
>> printf( "%s%d\n",
>> "result is ", result );
>> return 0;
>>}
>
>Thanks,
>boz

Syntactically, there is nothing wrong with your source.

It should pitch a fit when you run it.

From your question, I am assuming you compiled it and got no error. Did you try running it ?


--
------------------------------------------------------------------------
Dan White
------------------------------------------------------------------------
"Sometimes I think the surest sign that intelligent life exists
elsewhere in the universe is that none of it has tried to contact us."
Calvin (Bill Waterson)


  • Prev by Date: Re: Aqua Interface Guidelines & Close Window location ?
  • Next by Date: Re: Aqua Interface Guidelines & Close Window location ?
  • Previous by thread: Re: division by zero not an error for cc?
  • Next by thread: Re: division by zero not an error for cc?
  • Index(es):
    • Date
    • Thread