1 / 15

Math

Math. By: Mr. McTavish. BASIC OPERATIONS. Addition: + Subtraction: - Multiplication: * Division: / Modulus (division remainder): %. Integer addition. Int32 intOp1 = 3; Int32 intOp2 = 4 ; Console.WriteLine ("Integer Addition: " + (intOp1 + intOp2). ToString ());.

valmai
Download Presentation

Math

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Math By: Mr. McTavish

  2. BASIC OPERATIONS • Addition: + • Subtraction: - • Multiplication: * • Division: / • Modulus (division remainder): %

  3. Integer addition • Int32 intOp1 = 3; • Int32 intOp2 = 4; • Console.WriteLine("Integer Addition: " • + (intOp1 + intOp2).ToString());

  4. Double addition • Double dblOp1 = 3.1; • Double dblOp2 = 4.2; • Console.WriteLine("Double Addition: " • + (dblOp1 + dblOp2).ToString());

  5. Integer Multiplication • Int32 intOp1 = 3; • Int32 intOp2 = 4; • Console.WriteLine("Integer Multiplication: " • + (intOp1 * intOp2).ToString());

  6. Double Multiplication • Double dblOp1 = 3.1; • Double dblOp2 = 4.2; • Console.WriteLine("Double Multiplication: " • + (dblOp1 * dblOp2).ToString());

  7. Integer Division • Int32 intOp1 = 3; • Int32 intOp2 = 4; • Console.WriteLine("Integer Multiplication: " • + (intOp1 / intOp2).ToString());

  8. Double Division • Double dblOp1 = 3.1; • Double dblOp2 = 4.2; • Console.WriteLine("Double Multiplication: " • + (dblOp1 / dblOp2).ToString());

  9. Integer Division • Int32 intOp1 = 3; • Int32 intOp2 = 4; • Console.WriteLine("Integer Multiplication: " • + (intOp1 / intOp2).ToString());

  10. Integer divided by double • Int32 intOp1 = 3; • Double dblOp2 = 4.2; • Console.WriteLine("Int Divided by Double: " • + (intOp1 / dblOp2).ToString());

  11. Integer modulus • Int32 intOp1 = 3; • Int32 intOp2 = 4; • Console.WriteLine("Integer Modulus: " • + (intOp1 % intOp2).ToString());

  12. Double modulus • Double dblOp1 = 3.1; • Double dblOp2 = 4.2; • Console.WriteLine("Double Modulus: " • + (dblOp1 % dblOp2).ToString());

  13. Exponents • Console.WriteLine("Exponents: " • + (Math.Pow(dblOp1,dblOp2).ToString()));

  14. Sine • Console.WriteLine("Sin (Warning: Radians!): " • + (Math.Sin(dblOp1).ToString()));Console.WriteLine("Sin (Warning: Radians!): " • + (Math.Sin(dblOp1).ToString()));

  15. Concatenation • Console.WriteLine(String.Concat("This ","will ","look ","like ","a ","sentence.\n\t","Cool!"));

More Related