Print expression as is without evaluating it
- by Raj
i want to print the expression Xmin and Ymin as is without calculating the final value .
i,e with the values of I and J as 1,2,3,4,5
example
when I=1
Xmin= Xmin ((1 - 1)*10 + (1 - 1)*1)
is there a way to do it .. I tried the following code, but no luck:
int a, g;
a = 10;
g = 1;
for (int J=1; J<=5; J++)
{
for (int I = 1; I <= 5; I++)
{
string Xmin = Convert.ToString((I - 1)*a + (I - 1)*g);
string Ymin = Convert.ToString((J - 1) * a);
Debug.WriteLine("X=" + Xmin + "Y=" + Ymin);
}
}