-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAssignment49_.java
More file actions
52 lines (43 loc) · 823 Bytes
/
Assignment49_.java
File metadata and controls
52 lines (43 loc) · 823 Bytes
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
package abhilash_Asignments;
//Multiple level of inhertiance using concept of interface ?
interface Mail
{
void Gmail();
void Ymail();
}
interface SocialNetwork
{
void instagram();
void facebook();
}
public class Assignment49_ implements Mail, SocialNetwork
{
@Override
public void instagram()
{
System.out.println("Instagram");
}
@Override
public void facebook()
{
System.out.println("face book");
}
@Override
public void Gmail()
{
System.out.println("Gmail");
}
@Override
public void Ymail()
{
System.out.println("yahoomail");
}
public static void main(String[] args) //Main Method
{
Assignment49_ A1 = new Assignment49_(); //creating an object for child class
A1.Gmail(); //inteface main Abstract methods
A1.Ymail();
A1.instagram();
A1.facebook();
}
}