-
Notifications
You must be signed in to change notification settings - Fork 73
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat (jupyter & eclipse / binding & abstract)
- Loading branch information
Showing
51 changed files
with
677 additions
and
561 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
13 changes: 13 additions & 0 deletions
13
src/src/pt/c02oo/s10polimorfismo/s02poligono/AppPoligonoPoli.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package pt.c02oo.s10polimorfismo.s02poligono; | ||
|
||
public class AppPoligonoPoli { | ||
|
||
public static void main(String[] args) { | ||
Poligono tr = new TrianguloRetangulo(6, 10); | ||
Poligono rt = new Retangulo(6, 10); | ||
|
||
System.out.println("Área do triangulo retângulo: " + tr.getArea()); | ||
System.out.println("Área do retângulo: " + rt.getArea()); | ||
} | ||
|
||
} |
24 changes: 24 additions & 0 deletions
24
src/src/pt/c02oo/s10polimorfismo/s02poligono/Poligono.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package pt.c02oo.s10polimorfismo.s02poligono; | ||
|
||
public class Poligono { | ||
private int altura; | ||
private int largura; | ||
|
||
|
||
public Poligono(int altura, int largura) { | ||
this.altura = altura; | ||
this.largura = largura; | ||
} | ||
|
||
public int getAltura() { | ||
return altura; | ||
} | ||
|
||
public int getLargura() { | ||
return largura; | ||
} | ||
|
||
public float getArea() { | ||
return 0; | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
src/src/pt/c02oo/s10polimorfismo/s02poligono/Retangulo.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package pt.c02oo.s10polimorfismo.s02poligono; | ||
|
||
public class Retangulo extends Poligono { | ||
public Retangulo(int altura, int largura) { | ||
super(altura, largura); | ||
} | ||
|
||
public float getArea() { | ||
return getAltura() * getLargura(); | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
src/src/pt/c02oo/s10polimorfismo/s02poligono/TrianguloRetangulo.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package pt.c02oo.s10polimorfismo.s02poligono; | ||
|
||
public class TrianguloRetangulo extends Poligono { | ||
public TrianguloRetangulo(int altura, int largura) { | ||
super(altura, largura); | ||
} | ||
|
||
public float getArea() { | ||
return getAltura() * getLargura() / 2; | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
...s10polimorfismo/s02pessoa/Alcebiades.java → ...s10polimorfismo/s03pessoa/Alcebiades.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...2oo/s10polimorfismo/s02pessoa/Alguem.java → ...2oo/s10polimorfismo/s03pessoa/Alguem.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...10polimorfismo/s02pessoa/AppPessoa01.java → ...10polimorfismo/s03pessoa/AppPessoa01.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...oo/s10polimorfismo/s02pessoa/Melissa.java → ...oo/s10polimorfismo/s03pessoa/Melissa.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
...s10polimorfismo/s03tempo/AppTempo01a.java → ...s10polimorfismo/s04tempo/AppTempo01a.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package pt.c02oo.s10polimorfismo.s03tempo; | ||
package pt.c02oo.s10polimorfismo.s04tempo; | ||
|
||
import java.util.Scanner; | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
...s10polimorfismo/s03tempo/AppTempo01b.java → ...s10polimorfismo/s04tempo/AppTempo01b.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.