A nested if statement
class MainClass
{
public static void Main()
{
int intValue = 1500;
string stringValue = " ";
if (intValue < 1000)
{
System.Console.WriteLine("intValue < 1000");
}
else
{
System.Console.WriteLine("intValue >= 1000");
if (stringValue == "closed")
{
System.Console.WriteLine("closed");
}
}
}
}
Output intValue >= 1000
|
HTML code for linking to this page:
Related in same category :
-
-
-
-
-
-
-
-
|