We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c5df1f2 commit 14b4cd6Copy full SHA for 14b4cd6
AbstractClassExample.cs
@@ -0,0 +1,37 @@
1
+using System;
2
+
3
+namespace AbstractClassExample
4
+{
5
+ public abstract class AreaClass
6
+ {
7
+ public abstract int Area();
8
+ }
9
10
+ internal class Square : AreaClass
11
12
+ private readonly int _side = 0;
13
14
+ public Square(int n)
15
16
+ _side = n;
17
18
19
+ public override int Area()
20
21
+ return _side * _side;
22
23
24
25
26
27
+ internal static class Program
28
29
+ public static void Main(string[] args)
30
31
+ var square = new Square(6);
32
+ Console.WriteLine(square.Area());
33
34
35
36
37
+}
0 commit comments