struct Address { private int plotno; private String city; } Address a = new Address(); Address b; b = a;
struct Book { private String name; private int noofpages; private Single price; } Book b = new Book();
class Trial { int i; Decimal d; } struct Sample { private int x; private Single y; private Trial z; } Sample ss = new Sample();
namespace CuriousTabConsoleApplication { struct Sample { public int i; } class MyProgram { static void Main(string[] args) { Sample x = new Sample(); x.i = 10; fun(ref x); Console.Write(x.i + " "); } public static void fun(ref Sample y) { y.i = 20; Console.Write(y.i + " "); } } }
class Sample
{
int len;
public int Length
{
get
{
return len;
}
}
}
class Sample
{
public int Length
{
get
{
return Length;
}
}
}
class Sample
{
int len;
public int Length
{
get
{
return len;
}
set
{
len = value;
}
}
}
class Sample
{
int len;
public int Length
{
Readonly get
{
return len;
}
}
}
class Sample
{
int len;
public int Length
{
get
{
return len;
}
}
}
class Sample
{
public int Length
{
set
{
Length = value;
}
}
}
class Sample
{
int len;
public int Length
{
get
{
return len;
}
set
{
len = value;
}
}
}
class Sample
{
int len;
public int Length
{
WriteOnly set
{
len = value;
}
}
}
class Sample
{
int len;
public int Length
{
set
{
len = value;
}
}
}
class Sample
{
int len;
public int Length
{
set
{
len = value;
}
}
}
Student[3] = 34;
Student s = new Student(); s[3] = 34;
Student s = new Student(); Console.WriteLine(s[3]);
Console.WriteLine(Student[3]);
Student.this s = new Student.this(); s[3] = 34;
Sample m = new Sample();
int l;
l = m.Length;
Sample m = new Sample();
m.Length = m.Length + 20;
Sample.Length = 20;
Console.WriteLine (Sample.Length);
Sample m = new Sample();
m.Length = 10;
Sample m = new Sample();
m.Length = 10;
Student s = new Student(); s[1, 2] = 35;
class Student
{
int[ ] a = new int[5, 5];
public property WriteOnly int this[int i, int j]
{
set
{
a[i, j] = value;
}
}
}
class Student
{
int[ , ] a = new int[5, 5];
public int property WriteOnly
{
set
{
a[i, j] = value;
}
}
}
class Student
{
int[ , ] a = new int[5, 5];
public int this[int i, int j]
{
set
{
a[i, j] = value;
}
}
}
class Student
{
int[ , ] a = new int[5, 5];
int i, j;
public int this
{
set
{
a[i, j] = value;
}
}
}
class Student
{
int[ , ] a = new int[5, 5];
public int this[int i, int j]
{
set
{
a[i, j] = value;
}
}
}
Comments
There are no comments.Copyright ©CuriousTab. All rights reserved.