5 Replies Latest reply: Mar 20, 2007 1:09 AM by 807599 RSS

    Being able to use a double and an int in a equation

      Did a little searching for the answer before asking both in the api and here on the forums, as well as my old programs but just can't seem to find the answer. I need to be able to use an int and a double in a equation where the answer should be an int. Here is an example of exactly what I'm trying to do:

      int answer=0;
      int number=1;
      int number2=3;
      double number3=1.5


      I want an int as the answer but I need the double for the equation so please tell me what I'm forgetting. Thanks.