Variable in C# :
- A variable represents a numeric or string value or an object of a class. The value that the variable stores may change, but the name stays the same. A variable is one type of field. The following code is a simple example of how to declare an integer variable, assign it a value, and then assign it a new value.
int x = 15; // x holds the value 15 x = 7; // now x holds the value 7
string words = "Hello, World!";
Response.write(words);
Conditional Statement :
In , conditional statements, conditional expressions and conditional constructs are features of a programming language, which perform different computations or actions depending on whether a programmer-specified boolean condition evaluates to true or false
If - Else Statement Coding;
protected void Page_Load(object sender, EventArgs e){string str = "hellow";if (str == "hellowe"){Response.Write("yes"); } else { Response.Write("No");}}
No comments:
Post a Comment