Perform arithmetic operation on floating values in c#, DOT NET Programming

Assignment Help:

Perform Arithmetic operations on Floating Values - C# Program

Hello, I've been trying so many codes for this but those codes didn't work well. Please write the code for Perform Arithmetic Operations on Floating Values in c#.


Related Discussions:- Perform arithmetic operation on floating values in c#

Djvu view and setup- sourcecode with nice ui, Djvu view and setup,  sourcec...

Djvu view and setup,  sourcecode with nice UI Project Description: i want an application build for viewing djvu files -must include setup -must include source code -

Explain the wsdl, Explain the WSDL. WSDL is a short form for Web Servi...

Explain the WSDL. WSDL is a short form for Web Services Description Language, which is used to explain a Web service in terms of the messages that it forms and accepts. The WS

Dcom, What is DCOM? DCOM is different from COM in that it allows for cr...

What is DCOM? DCOM is different from COM in that it allows for creating objects distributed around  a network, and a protocol for invoking that object's methods, & secures the

Accepting a list of 5 items - c# program, Accepting a List of 5 Items - C# ...

Accepting a List of 5 Items - C# Program Hello, I've been trying so many codes for this but those codes didn't work well. Please write the code for Accepting a List of 5 Items

What is asp.net authentication providers and iis security, What is ASP.NET ...

What is ASP.NET Authentication Providers and IIS Security? ASP.NET executes authentication using authentication providers, which are code modules that determine credentials and

Converting rs. to paisa - c# program, Converting Rs. to Paisa - C# Program ...

Converting Rs. to Paisa - C# Program Need the code of C# Program for Converting Rs. to Paisa.

What is strong-typing versus weak-typing, What is strong-typing versus weak...

What is strong-typing versus weak-typing? Which is preferred? Why? Strong type is checking the types of variables as soon as possible, usually at compile time. While weak typing

Ewdedewdew, ssasadsdsdsddewdewdwedewdewdewededewdewdewdewdewdewdewdwedssa s...

ssasadsdsdsddewdewdwedewdewdewededewdewdewdewdewdewdewdwedssa sdedwdew dedewdew ewdewdew ewdewdew dedew ewdew ewd ewde ew ew

Jacob

2/11/2013 6:41:58 AM

Program code for Arithmetic Operations on Floating Values

using System;

class floatdemo

{

  public static void Main()

 {  

   string s1,s2;

   float a,b;

 Console.Write("Enter no 1 # "); // Display to enter no. 1

  s1 = Console.ReadLine (); // save the  number in a string variable s1

  a = float.Parse (s1); // the string s1 is converted into float type variable

 Console.Write("Enter no 2 # "); //Display to enter no. 2

  s2 = Console.ReadLine (); // save the  number in a string variable s2

  b = float.Parse (s2); // the string s2 is cinverted into float type variable

    // Here er converted both the string variables to float because we wanted to do 

   // float / numeric manipulation with the inputted string variables

   Console.WriteLine(""); // Blank line

  Console.WriteLine("*** Integer manipulations ****");

  Console.WriteLine(""); // Blank line    

   // Integer manipulations  

  Console.WriteLine("No1 + No2 = " + (a+b));

  Console.WriteLine("No1 - No2 = " + (a-b));

  Console.WriteLine("No1 / No2 = " + (a/b));

  Console.WriteLine("No1 * No2 = " + (a*b));

  Console.WriteLine("No1 % No2 = " + (a%b));

 Console.ReadLine();

  }

}

Bella

2/11/2013 6:43:18 AM

Thanks for your Experts suggestion.

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd