• 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 : arithmetic in Cocoa
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re : arithmetic in Cocoa


  • Subject: Re : arithmetic in Cocoa
  • From: jean Bousquet <email@hidden>
  • Date: Fri, 04 Jul 2003 19:51:16 +0200

You don't need.
Assuming that N is got from user through a textField, you get directly a C
variable with :
N=[textField doubleValue]
aso for all the other variables you need
then you may keep your C formula unchanged because you deal with normal C
variables.
You use objective C for UI but could keep classic C for calculations.

Jean Bousquet


> Date: Fri, 4 Jul 2003 16:24:46 +0200
> Subject: arithmetic in Cocoa
> From: Cyprien <email@hidden>
> To: email@hidden
>
> How do you translate a Formula like this one in Objective-C?
>
> k = 2*round(N/Fs*Fin/2) + 1
>
> Do I really have to use method such as NSDecimalRound() and so on to
> calculate this?
>
> Cyprien
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: awakeFromNib and windowWillLoad : basic question
  • Next by Date: Basic NSGraphicsContext question
  • Previous by thread: Lives only in PB...
  • Next by thread: Custom open file panel
  • Index(es):
    • Date
    • Thread