Program for assigning the values to variables, DOT NET Programming

Program for Assigning the Values to Variables

Hello i am unable to find the code of assigning the values to variables in c#. Please write a program for me of assigning  values  to  Variables in C#.

 

Posted Date: 2/11/2013 4:33:56 AM | Location : United States





Please try this once.

Program - Assigning values to variables

using System; 

class SampleMath 

  public static void Main() 

  { 

   double x = 2.0;                        // declaring a variable named x of type double & assigning it value 2.0 

   double y = 3.0;                        // declaring a variable named y of type double & assigning it value 3.0 

   double z ;                                 // declaring a variable named z of type double 

   z = x + y;  

   Console.WriteLine("x = " + x + ", y = " + y + " & z = " + z); 

   Console.ReadLine(); 

  } 

Posted by Harry | Posted Date: 2/11/2013 4:48:11 AM

Hi. Thank you for this example. I look forward to going through your other program codes. I''ve been trying to look up this kind of stuff on the? web and its a pain. Thank you for your expert Advice.

Posted by Jack | Posted Date: 2/11/2013 4:52:22 AM


Related Discussions:- Program for assigning the values to variables, Assignment Help, Ask Question on Program for assigning the values to variables, Get Answer, Expert's Help, Program for assigning the values to variables Discussions

Write discussion on Program for assigning the values to variables
Your posts are moderated
Related Questions
ASP .NET MVC Tutor Project Description: Work with me and assist with troubleshooting lessons, describe in easy to understand terms how to accomplish certain tasks, provide co

Develop Nesting software with unit costing for gasket manufacturing Project Description: Our current gasket costing software is old and antiquated and has limited use interna

I want a C# school project Project Description: The project is made in C# and haves a database connection. We have some small problems asking up data from the database.

What are the criteria necessary for an effective and efficient network? a. Performance It can be measured in several ways, including transmit time and response time. b

How would ASP and ASP.NET apps run at the same time on the same server? Both ASP and ASP.net can be run at similar server, becuase IIS has the capability to respond/serve both

Project Description: Hi I am seeking for an MVC developer who is good at Online Store, CMS and Ecommerce. Skills required: .NET, HTML, eCommerce, Shopping Carts, Website D

What is the DataContext class and how is it related to LINQ? After you add a LINQ to SQL Classes item to a project and open the O/R Designer, the empty design surface shows an

Find out the Factorial - C# Program I've been trying so many codes for this but those codes didn't work well. Please write the code for find out the factorial of an integer nu

Explain Component diagrams Package: - The Package logically make group of element of a UML model. Component: - It is the actual physical module or implementation of

mailer - mail sender Project Description: I want a mailer: -run on Windows Server 2008 -use how many theard i need -more details speak on private Skills required