Welcome to mirror list, hosted at ThFree Co, Russian Federation.

decimal-array.cs « tests « mono - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: beb0079718d625ce1d8f5a5f4576c3f10ab842d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
using System;

class Test
{
	public static int Main()
	{
		decimal[,] tab = new decimal[2,2] {{3,4},{5,6}};
		bool b1 = false;
		decimal d;

		try {
			d = tab[1,2];
		} catch (Exception e) {
			b1 = true;
		}

		if (!b1)
			return 1;
		
		d = tab[1,1];
		if (d != 6)
			return 1;
		
		return 0;
	}
}