SHARE
TWEET

3

Xrocky Dec 8th, 2019 77 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package formalab.seance5.exercice1;
  2.  
  3. public class ExempleHeritage {
  4.  
  5.     public static void main(String[] args) {
  6.         // TODO Auto-generated method stub
  7.  
  8.         Personne p1 =new Personne();
  9.         p1.nom="ALi";
  10.         p1.prenom="benAli";
  11.         p1.age=22;
  12.        
  13.         p1.parler();
  14.         p1.marcher();
  15.         p1.afficher();
  16.        
  17.         Etudiant e1=new Etudiant();
  18.         e1.nom="sallah";
  19.         e1.prenom="bensalah";
  20.         e1.age=22;
  21.          
  22.         e1.parler();
  23.         e1.marcher();
  24.         e1.afficher();
  25.        
  26.    
  27.     }
  28.  
  29. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top