Skip to content

Commit

Permalink
Fixed package name. Made main method static
Browse files Browse the repository at this point in the history
  • Loading branch information
SnehaNarendran01071998 committed Oct 21, 2021
1 parent fbc2319 commit eb27028
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion Java/OOP/Abstraction/Person.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
package Inheritance;
package Abstraction;


public abstract class Person {
private String firstName;
Expand Down
2 changes: 1 addition & 1 deletion Java/OOP/Abstraction/Student.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package Inheritance;
package Abstraction;

public class Student extends Person {
private String ownerName;
Expand Down
2 changes: 1 addition & 1 deletion Java/OOP/Abstraction/Teacher.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package Inheritance;
package Abstraction;

public class Teacher extends Person {
private String subject;
Expand Down
4 changes: 2 additions & 2 deletions Java/OOP/Abstraction/Test.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package Inheritance;
package Abstraction;

public class Test {
public void main(String[] args){
public static void main(String[] args){
Person teacher1 = new Teacher("John", "Tarbet", "Sri Lanka", "Science");
Person teacher2 = new Teacher("Ann", "Tarbet", "Australia", "Maths");

Expand Down

0 comments on commit eb27028

Please sign in to comment.