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
What is an application domain? Previously "PROCESS" were used as the security boundaries. One of the process has its own virtual memory and does not overlap the  another proces

Prepare .NET TWAIN application to control digital imaging sensor Project Description: We are seeking somebody to create a .NET TWAIN application which will activate a digital

How does output caching work in ASP.NET?    Output caching is a powerful method that enhances request/response throughput by caching the content generated from dynamic pages. O

I need to develop a new website. Previous site was not good and I need better one with not only static but using also more details . Skills required: .NET, MySQL, C# Programm

The problem statement is pretty simple. We need a software implementation of a Point of Sale terminal at a typical store. The users of the system are the cashiers sitting at the sa

What is the use of a .disco file? A client application uses a .disco file to locate or discover the documents that have the description of a Web service. The .disco file having

You can post back to any of the page and pages in other application, too. But if you are posting pages to other application, the PreviousPage property will return null. This is an

What is DBCC? The Database Consistency Checker Commands (DBCC) is used to check the logical and physical consistency of the database structure.The DBCC statements can fix and d

how we can display a alphabets by identifies an image and if its different than show someother alpbabets.

What are advantages of SQL 2000 over SQl 7.0? 1)User-Defined Functions: The User-Defined Functions (UDFs) -- one or moreTransact-SQL statements may be used to encapsulate the